Analyzing output

Report a typo

import asyncio

async def print_numbers():
    for i in range(5):
        await asyncio.sleep(0.5)
        print(i, end=' ')

async def main():
    task1 = asyncio.create_task(print_numbers())
    task2 = asyncio.create_task(print_numbers())

    await task1
    await task2

asyncio.run(main())

What is the output of the code snippet? Select the correct option.

Try to answer this question without running this code at first
Select one option from the list
___

Create a free account to access the full topic