A friend of mine left her position teaching physics at FC College and took a job at PGCs. She was working in a cubicle i

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

A friend of mine left her position teaching physics at FC College and took a job at PGCs. She was working in a cubicle i

Post by answerhappygod »

A friend of mine left her position teaching physics at FCCollege and took a job at PGCs. She was working in a cubicle in thebasement of a huge building, and the nearest women's prayer roomwas two floors up. She proposed to her boss that women be allowedto pray in the men's pray room.
The boss agreed, provided that the following synchronizationconstraints can be maintained:
• There cannot be men and women in the prayer room at the sametime.
• There should never be more than three employees in the prayerroom
You are supposed to write a synchronization solution for thisproblem and implement it in C language.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply