Ornamental Garden - Message Passing

In this example, the Ornamental Garden is implememented using message passing. The East and West Turnstile threads signal the Count thread when a person passes through the turnstile. The Count thread waits for a message from East then West. Can people enter from the west if no-one is entering from the east?

Unable to load applet

View Source

Channel Source

Demo List