Another very simple example on how to use Ada tasks.
Ada
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
concurrent
sequential
.gitignore
README

README

This is a simple example on how to use tasks and protected objects in Ada to
solve the problem of emptying a Pez dispenser. Yea, I know it's not the most 
common of problems, but there you have it.

The sequential program solves it sequentially while the concurrent program
solves it by starting a bunch of concurrent workers.

To compile and execute:

   $ cd sequential
   $ gnatmake -P sequential.gpr
   $ time sequential

Substitute "sequential" with "concurrent" in the above to try the concurrent
program.

Enjoy!