Figure 1 shows a grid representing a 3x3 landing zone system for a cargo drone delivery network.
Figure 1
| K | L | M | |
|---|---|---|---|
| 1 | |||
| 2 | Drone | ||
| 3 |
Figure 2 shows an incomplete Python program designed to validate the user's landing zone input.
Figure 2
isValid = False
while isValid == False:
zone = ""
while len(zone) != 2:
zone = input("Enter landing zone (e.g. L2): ")
zone = zone.upper()
Extend the program from Figure 2 so it completes the other checks needed to make sure a valid landing zone code is entered.
The landing zone code is valid if:
Your extended program must:
isValidYou should use indentation as appropriate, meaningful variable names, and correct Python syntax in your answer.
298 exam-style questions on AQA GCSE Computer Science Programming concepts. Each one has a worked solution and a mark scheme showing where the marks go.