initial commit
This commit is contained in:
13
Python/OOP2/test.py
Normal file
13
Python/OOP2/test.py
Normal file
@ -0,0 +1,13 @@
|
||||
import asyncio
|
||||
|
||||
|
||||
async def sleep_print(i: str) -> None:
|
||||
print(i)
|
||||
await asyncio.sleep(5)
|
||||
|
||||
|
||||
async def main() -> int:
|
||||
await asyncio.gather(*[sleep_print(i) for i in range(5)])
|
||||
|
||||
|
||||
asyncio.run(main())
|
Reference in New Issue
Block a user