Python Everyday 19: Coroutine

No thread-locks, no thread switching, amazing effective execution efficiency, that’s why you feel hard to say don’t love the Coroutine. Today, I write a consumer and a producer to get memory usage logs by using coroutine, code as follow: