subject
Engineering, 02.03.2020 19:27 dayi80

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 customer arrives 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 the same order that they were in originally. Whenever a car leaves, all cars to the south are moved forward so that at all times all the empty spaces are in the south part of the garage. Write a program that reads a group of input lines. Each line contains an a for arrival and d for departure and a license plate number (example: 979WJC). Cars are assumed to arrive and depart in the order specified by the input. The program should print a message each time that a car arrives or departs. When car arrives, the message should specify whether or not there is room in the garage for the car. If there is no room for a car, the car then proceeds to the Knockemdead garage...which is similar to the Scratchemup. There is room for 8 cars at the Knockemdead garage. If both garages are full, cars wait in the street near the Scratchemup garage for a space...and of course they are queued up in the street. The size of the street queue is also 8.So in summary, when a car arrives it tries to park in the Scratchemup garage. If there is no room, it goes to the Knockemdead garage. If there is no room there, it waits in the street. A message indicates which garage it is in (or the street). When room becomes available, and a car moves from the street to one of the garages, another message should be printed. When a car departs, a message indicates that a car has departed and also indicates which garage (or the street). This departure message should also include the number of times the car was moved within the garage (including the departure itself, but not the arrival). This number is zero if the car departs from the street and not from one of the garages.

ansver
Answers: 3

Another question on Engineering

question
Engineering, 03.07.2019 14:10
The y form of iron is known as: a) ferrite b) cementite c) perlite d) austenite
Answers: 3
question
Engineering, 04.07.2019 18:10
Aloaded platform of total mass 500 kg is supported by a dashpot and by a set of springs of effective stiffness 72 kn/m. it is observed that when the platform is depressed through a distance x = 12.5 cm below its equilibrium position and then released without any initial velocity; it reaches its equilibrium position in the shortest possible time without overshoot. find the position and velocity of the loaded platform 0.10 sec. after its release. if a further load of 400 kg is added to the platform, find, i) the frequency of damped vibrations, and i) the amplitude of vibration after 2 complete oscillations, given that the initial amplitude is 15 cm.
Answers: 1
question
Engineering, 04.07.2019 18:10
What are the two (02) benefits, which may result from a successful implementation of preventive maintenance (pm) program in an organization? (clo3)a)- lean manufacturing b)-overlapping responsibilities c)-the planner is not qualified d)-accurate contractor information e)-reduction in equipment redundancies f)-accurate stores information
Answers: 3
question
Engineering, 04.07.2019 18:20
Asimple rankine cycle uses water as the working fluid. the water enters the turbine at 10 mpa and 480c while the condenser operates at 6 kpa. if the turbine has an isentropic efficiency of 80 percent while the pump has an isentropic efficiency of 70 percent determine the thermal efficiency
Answers: 1
You know the right answer?
The Scratchemup parking garage contains a single lane that holds up to 10 cars. Cars arrive at the s...
Questions
question
History, 26.03.2020 21:04
question
Advanced Placement (AP), 26.03.2020 21:04
question
Spanish, 26.03.2020 21:04
Questions on the website: 13722360