LearnPy Hub
← Async Basics problems
Easy

Async Countdown

Write async def countdown(n) that prints n, n−1, …, 1, awaiting asyncio.sleep(0.001) between numbers, and then prints Lift off!.

Input

One integer n ≥ 1.

Output

Lines.

Sample 1

Input
3
Output
3
2
1
Lift off!

Sample 2

Input
1
Output
1
Lift off!
solution.py
Output appears here
Async Countdown · Python practice problem · LearnPy Hub