Hey guys,

I have a question reagarding a simulation assignment I was given in my C++ class. The idea is to simulate a array based queue of planes waiting to land on a runway. The inputs are...

1 lenght of simulation (hour:minutes)
2 average time between addition of planes to queue
3 time it takes to land a plane (i.e. the speed at which planes can be removed from the queue)

My problem is how to simulate time. The best I can come up with is to reduce the lenght of the simulation to total time in minutes and then run a for or do/while loop that cycles for that many minutes. That way I can consisly control what it happening at each minute. I was thinking something like this...

Code:
for( int c = 0; c < SimulationTimeInMinutes; c++){
	
	function to add plane(if conditions are correct)
	function to remove plane(if conditions are correct)

}


Is there a better way to simulate time than using loops? Thanks