Concurrent Coroutines – Concurrency is not Parallelism
PLEASE find an updated version of this on my Medium: https://medium.com/@s1m0nw1/the-difference-between-concurrency-and-parallelism-explained-using-kotlin-83f4159581d. On Kotlin Coroutines and how concurrency is different from parallelism The official docs describe Kotlin Coroutines as a tool "for asynchronous programming and more", especially are coroutines supposed to support us with "asynchronous or non-blocking programming". What exactly does this mean? How is "asynchrony" related to the terms "concurrency" and "parallelism", tags we hear about a lot in this context as well. In this article, we will see that coroutines are mostly concerned about concurrency and not primarily about parallelism. Coroutines provide sophisticated means which help us structure code to make it highly concurrently executable, also enabling parallelism, which isn't the default behavior though. If you don't understand the difference yet, don't worry about it, it will get clearer…