Hello I ma trying to practice on Data structure using java. I solved a lot of problems but this one looks interesting but I need some help understanding what I really have to do ...

write a program that simulates the operation of a busy airport that has only 2 runways to handle all takeoffs and landings. you may assume that each takeoff or landing takes 15 minutes to complete. one runway request is made during each five-minute interval, and the likelihood of a landing request is the same as for a takeoff request. priority is given to planes requesting a landing. if a request cannot be honored, it is added to a takeoff or a landing queue. your program should simulate 120 minutes of activity at the airport. each request for runway clearance should be time-stamped and added tto the appropriate queue. the outputs of your program should include the final queue contents, the number of landings and takeoffs completed, and the average number of minutes spent in each queue.

I just didn't understand what I have to do with the time and the queue and the 2 runways ...
May someone explain to me what I am supposed to do?
I don't want the solution code just explanation ...
Thank you :)

Recommended Answers

All 2 Replies

Create a class called request storing all the data on the flight ie number time in queue etc
Create two queue collections [ queue<dataType> = new LinkedList(); ]

Use that concept to build your program around.
I like the idea of this program, sounds good.

Hello I recently got set a task very similar to this and just wondered if there is any help you can give me.

I have experience coding but not in Java. Just wondered how you ended up approaching the problem?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.