Give the solution for this synchronization problem using a monitor. Explain why your solution is correct. Notice that only the synchronization problem is solved inside the monitor and actual computational work must be done outside the monitor. State all the assumptions needed for your monitor.