A monitor is supposed to solve problems with semaphores in concurrent environments.
I'm looking for a good analogy using a monitor verses semaphore.
Please use information for the analogy:
4 tasks (TaskA, TaskB, TaskC, TaskD)
1 variable varX
Each Task wants to manipulate varX based on some event.