Python Quest  /  Mission 6
Loading Python...
World 1 · Mission 6

Security Drones

Four security drones are blocking Bolt's route. This time, the program should continue repeating while drones remain active. Use a while loop to clear the security zone.

Security Zone

Your while loop controls the shutdown sequence.

Active drones
4 / 4
Drone 1
🛸
ACTIVE
Drone 2
🛸
ACTIVE
Drone 3
🛸
ACTIVE
Drone 4
🛸
ACTIVE
Security zone blocked.
Mission objective

Repeat while a condition is true

The variable drones_remaining starts at 4.

Keep disabling drones while the value is greater than 0. After each drone is disabled, reduce the value by one.

Use while drones_remaining > 0
Decrease drones_remaining by 1
Disable all four drones

Check your understanding

If drones_remaining started at 3 and decreased by one each time, how many times would this loop run?

Mission complete!

You used a while loop to repeat instructions until a condition became false.

Your Python code

Complete the while condition