Can a Coroutine is useful without Asynchronous IO ?
Coroutine is a way of doing concurrent programming without the need of Thread. For more information regarding coroutine, go to asyncoro and asyncio-task . Coroutine has numerous advantages when used with asynchronous IO. But in this post I am analyzing whether coroutine can be used without it and also checking whether coroutine can be used to replace threads in most scenarios as threads itself is not running in parallel due to GIL in python. Below are the advantage and disadvantage of coroutines (without Asynchronous IO) when compared against threads. Advantage 1. No locking mechanism required (in most cases) as the next coroutine will run only after the current coroutine yields. 2. No thread, so no context switch required between coroutine execution. Disadvantage 1. If a coroutine gets blocked, it will block all other coroutines as well as there is...