please rate - thanks
hope this is what you need
car arrive
yes:
lot full?
yes:
put car in wait queue
no:
put car in lot queue
car depart
yes:
car in lot queue?
yes:
car in front of queue?
yes:
remove car from front of lot queue
move rest of cars up
any car in wait queue?
yes:
put front car in lot queue
move cars up in wait queue
no:
loop1:
put front car in hold stack
car in front of lot?
no:
go to loop1
yes:
remove car from front of lot queue
move rest of cars up
any car in wait queue?
yes:
put front car in lot queue
move cars up in wait queue
pop cars from hold stack put them back in queue
move cars in queue up 1
any car in wait queue?
yes:
put front car in lot queue
move cars up in wait queue
no:
car in front of wait lot?
yes:
loop2:
put front car in hold stack
car in front of wait lot?
no:
go to loop2
yes:
remove car from front of wait queue
move rest of cars up
pop cars from hold stack put them back in wait lot
move cars in lot up 1
The laughs parking garage contains a single lane that hold up to ten cars. Cars arrive...
The Scratchemup parking garage contains a single lane that holds up to 10 cars. Cars arrive at the south end of the garage and leave from the north end. If a customerarrives to pick up a car that is not the northernmost, all cars to the north of his car are moved out, her car is driven out, and the other cars are restored in thesame order that they were in originally. Whenever a car leaves, all cars to the...
The Bashemin Parking Garage contains a single lane that can hold up to ten cars. Arriving cars enter the garage at the rear and are parked in the empty space nearest to the front. Departing cars exit only from the front. If a customer needs to pick up a car that is not nearest to the exit, then all cars blocking its path are moved out temporarily, the customer's car is driven out, and the other cars are restored in...
The CSC326 parking garage contains 2 lanes, each capable of holding up to 10 cars. There is only a single entrace/exit to the garage at one end of the lanes. If a customer arrives to pick up a car which is not nearest the exit, all cars blocking the car's path are moved into the other lane. If more cars still must be moved out of the way, they go into the street. When the customer's car is driven out,...
PLease, I need help with this Code. PLease create correctly
documentations comments for better understanding.
This is the input:
JAV001 ARRIVE
JAV002 ARRIVE
JAV003 ARRIVE
JAV004 ARRIVE
JAV005 ARRIVE
JAV001 DEPART
JAV004 DEPART
JAV006 ARRIVE
JAV007 ARRIVE
JAV008 ARRIVE
JAV009 ARRIVE
JAV010 ARRIVE
JAV011 ARRIVE
JAV012 ARRIVE
JAV013 ARRIVE
JAV014 ARRIVE
JAV006 DEPART
JAV014 DEPART
JAV013 DEPART
JAV005 DEPART
JAV015 ARRIVE
JAV010 DEPART
JAV002 DEPART
JAV015 DEPART
JAV014 DEPART
JAV009 DEPART
JAV003 DEPART
JAV008 DEPART
JAV007 DEPART
JAV012 DEPART
JAV011...
A parking garage charges a $2.00 minimum fee to park for up to three hours. The garage charges an additional $0.50 per hour in excess of these initial three hours. The maximum charge for any given 24 hour period is $10.00. Assume no car parks for longer than 24 hours at a time. Write a program that calculates and prints the total parking charges for the customers who parked their cars in this garage (at least 4 cars) and the...
Programming Assignment #2 (Arrays) I. The Assignment This assignment is to take your Garage class from the previous assignment and modify it so that it uses an array of Car objects as the principal data structure instead of an ArrayList-of-Car. This is an example of the OOP principle of information hiding as your Car and test classes will not have to be modified at all. Unless you broke encapsulationon the previous assignment, that is II. Specifications Specifications for all 3...
Write code for the following program in C. As per proper coding practice, plan out your program with psuedocode and include this before the main function. I visited Fields Museum in Chicago few months ago to look at Mummy’s. You have been asked to write a program that can be used to control the number of people who can be in the exhibition room at the same time. Groups of people can always leave the room (if they are inside),...
I need help in C++ . Project 3 – Parking Deck Ticketing System Objectives: Use if, switch, and loop statements to solve a problem. Use input and output statements to model a real world application Incorporate functions to divide the program into smaller segments Instructions: Your task is to write a program that simulates a parking meter within the parking deck. The program will start by reading in the time a car arrives in the parking deck. It will then...
This program will provide the user the tools to make up trains from a file of available cars. The car data will be the reporting identifier, car type, weight (in tons) and length (in feet) for each car. The user can select to make up a train by total weight, total length or car type. The user will be able to display any train’s consist, and will be able to delete a train (returning the cars to the pool of...
Overview: In this lab, you will write a program called JobScheduler; it should take a single input file as a command-line argument. Each line in the input file has the following format: <job #> <priority> <arrival time (sec)> <duration (sec)> e.g. a file might contain: 1 3 10 100 5 2 20 50 8 4 5 100 (all values will be positive integers) These jobs might represent computer programs (or threads) that need to be run by the operating system....