Join Slack
Powered by
Of course, the story is different if you need resu...
# coroutines
e
elizarov
11/29/2017, 10:22 AM
Of course, the story is different if you need
results
for all those parallel tasks to do something with them. In this case you use
async
and
map
over the results again to retrieve them:
Copy code
(0..100).map { async { mySuspendingTask() } }.map { it.await() }
Open in Slack
Previous
Next