Step  1.  begin
Step  2.  for   ( periodic task)
Step  3.  while there is a free processor   and an unassigned tasks do
Step  4.    pick higher priority task
Step  5.    assign (pre-assigned or free processor)
Step  6.    if task executed within deadline
Step  7.      return “success”
Step  8.      else
Step  9.      return “failure”
Step  10.      endif
Step  11.  endwhile
Step  12. endfor
Pseudocode 3