Problem 4: Book a dinner reservation

While Mary is figuring out which airfield to land in, Louise needs to book a reservation at the Atlas Cafe. She was given a list of open times for the reservation. Based on the place they land, she needs to add 20 minutes (Courtenay) or 45 minutes (Smits Field) to their landing time to determine the reservation time. She also needs to book either a taxi (Courtenay) or the airfield loaner car (Smits Field). Write an algorithm that will take the necessary outputs from Problem 3 and determine which reservation time and mode of transportation she needs to book.

 

(You do not need to duplicate 3, just start 4 as if adding on to 3)

 

Solution (in English)

  • If originalLanding in Courtenay
  • Book taxi for landing time
  • Book Atlas reservation for originalLanding  + 20min
  • If “newLanding” please contact Airstrip marshall to reserve a loaner car.
  • Book Atlas reservation for “newLanding” + 45min

 

Solution (flow chart)