The Problem - Unisex Bathroom Problem.
Suppose there is only one working bathroom
in your
school.
It can be used by both men and women, but not by both at the same time.
Develop a Java program that solves this
problem.
Allow at most 5 men or women in the bathroom at the same time,
but ensure that your solution is fair to
both
sexes. If you use a semaphore, you must implement it yourself
(i.e. without
just making use of the Java methods for it). Marks will be
awarded for, among other things, creativity of solution.
Submission Stuff
- The project must be
submitted on or before Friday 17th
August 2015 (failure
to do so will
result in marks docked)
- The submission is to be by
email, details as
follows:
- subject: CA463 Assignment
Submission
- a statement by you stating
that it is your own
work except
where otherwise stated
- a short (2 page max)
report explaining how it
works, assumptions
made, how fairness satisfied etc