Problem 4 (continuation of Problem 3): 0204
What time to reserve Atlas Cafe for and whether to book a taxi or a loaner car:
Algorithm in English (just portion added to end of Problem 3 – program continues to run):
- If output from Problem 3 is Land at Smits Field:
- Input arrivalTimeSmitsField
- Calculate reservationTimeAtlasCafeSmitsLanding = arrivalTimeSmitsField + 45 minutes
- Output: reservationTimeAtlasCafeSmitsLanding (as clock time)
- Output: (println) “book loaner car”
- Stop Program
OR
- If output from Problem 3 is Land at Courtenay:
- Input arrivalTimeCourtenay
- Calculate reservationTimeAtlasCafeCourtenayLanding = arrivalTimeCourtenay + 20 minutes
- Output: reservationTimeAtlasCafeCourtenayLanding (as clock time)
- Output: (println) “book taxi”
- Stop Program
Algorithm as Flowchart (Adding Problem 4 info to Problem 3’s Flowchart):
mwilson
Well done, you’ve got the gist of it.
Here is my version: https://docs.google.com/document/d/1Mv4ZhDj3SjXL3M5hE1gY2XjY9Kb_1EUrU0-dg3abN14/edit?usp=sharing