79134731

Date: 2024-10-28 18:49:01
Score: 0.5
Natty:
Report link

A straightforward approach:

async def main():
    tasks: list[Coroutine] = create_tasks()
    max_con = 16

    while tasks:
        todo, tasks = tasks[:max_con], tasks[max_con:]
        await asyncio.gather(*todo)


asyncio.run(main())
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: KumaTea