Analyze and correct psuedocode solution implementing synchronization with semaphores

Closed

Bison World consists of a shopping mall and a buffalo ride that covers the 150 acre habitat. There are m visitors and n single-person vehicles. Visitors stroll around the mall at their leisure, then line up for the buffalo ride. When a buffalo vehicle is available, it allows the single passenger to climb aboard and drives around the habitat for a random amount of time. If the n buffalo vehicles are all taken, then a future rider waits; if a vehicle is available but no one is waiting, then the vehicle waits. The solution to this problem must synchronize visitor tasks and vehicle tasks using semaphores. Below is a potential solution. Assume initialization code exists. Correct any issues with this code, if any exist. Explain your position in detail.

Semaphore vehicleAvailable = 0, vehicleTaken = 0, vehicleFilled = 0,

visitorReleased = 0;

Visitor()

{

[url removed, login to view]();

[url removed, login to view]();

[url removed, login to view]();

[url removed, login to view]();

}

Vehicle()

{

while(True)

{

[url removed, login to view]();

[url removed, login to view]();

[url removed, login to view]();

Drive through habitat for some arbitrary amount of time;

[url removed, login to view]();

}

}

Skills: Software Architecture

See more: a true solution consists of a single, random signal, habitat, buffalo, line mall, visitor vehicle semaphore, using correct tables schema create query using either, semaphores, semaphore vehicleavailable vehicletaken vehiclefilled visitorreleased, acre, drive 1000 visitor day, rider, mall architecture, semaphore synchronization, implementing reliable transport protocol solution, architecture shopping mall, solution implementing reliable transport protocol, mall solution, solution explain, shopping mall architecture, semaphore, aboard software, programmers fail provide correct solution calculator, implementing single sign solution mysql, future mall

Project ID: #5096038

3 freelancers are bidding on average $67 for this job

srinichal

I look forward to deliver the project as I am an expert in coding and like to discuss further .

$94 USD in 3 days
(42 Reviews)
6.5
dobreiiita

Hello, I am programming expert and can surely help you with this project, Please let me know if you are interested. Thank You

$54 USD in 2 days
(39 Reviews)
5.6
Calleus

Hi, I have strong background in Operating Systems concepts and experience in Algorithms. Let me help you. I am ready to start.

$54 USD in 4 days
(13 Reviews)
4.5