home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: Graphics / Graphics.zip / os2apipm.zip / APIEXAM / PHIL / PHIL.ADS < prev    next >
Text File  |  1996-06-04  |  522b  |  22 lines

  1. --phil.ads
  2. with Society;
  3. package Phil is
  4.  
  5.   -- Dining Philosophers - Ada 95 edition
  6.   -- Philosopher is an Ada 95 task type with discriminant
  7.   -- Michael B. Feldman, The George Washington University,
  8.   -- July, 1995.
  9.  
  10.   task type Philosopher  is
  11.  
  12.     entry Start_Eating (Chopstick1 : in Positive;
  13.                         Chopstick2 : in Positive);
  14.  
  15.   end Philosopher;
  16.  
  17.  
  18.   type States is (Breathing, Thinking, Eating, Done_Eating,
  19.                   Got_One_Stick, Got_Other_Stick, Dying);
  20.  
  21. end Phil;
  22.