Talk:Dining philosophers: Difference between revisions

no output needed, anyway here an excerpt
No edit summary
(no output needed, anyway here an excerpt)
Line 9:
 
There should be examples of output ; for the novice members. --[[User:Arkapravo|Arkapravo]]19:43 , 8 April 2009 (GMT)
: Output does not add too much information: you do not achieve the task by looking at the output (that theoretically is not predictable); an example of run of the python code on my system gave:
 
<pre>Russel is hungry.
Russel starts eating
Aristotle is hungry.
Marx is hungry.
Marx swaps forks
Kant is hungry.
Kant starts eating
Budda is hungry.
Russel finishes eating and leaves to think.
Aristotle swaps forks
Marx starts eating
Kant finishes eating and leaves to think.
Budda swaps forks
Aristotle starts eating
Marx finishes eating and leaves to think.
Budda starts eating
Russel is hungry.
Russel swaps forks
Aristotle finishes eating and leaves to think.
Russel starts eating
Budda finishes eating and leaves to think.
Marx is hungry.
Marx swaps forks
Russel finishes eating and leaves to think.
Marx starts eating
Aristotle is hungry.
Aristotle starts eating
Kant is hungry.
Marx finishes eating and leaves to think.
Budda is hungry.
Budda starts eating
Russel is hungry.
Russel swaps forks
Budda finishes eating and leaves to think.
Aristotle finishes eating and leaves to think.
Kant starts eating
Russel starts eating
Budda is hungry.
Marx is hungry.
Marx swaps forks
Aristotle is hungry.
Kant finishes eating and leaves to think.</pre>
 
: And so on. --[[User:ShinTakezou|ShinTakezou]] 23:14, 11 April 2009 (UTC)