In Kotlin, withContext(Dispatchers.IO) ... is used to:
- Restart the activity
- Create a notification
- Update the UI
- Run blocking network/disk code on a background thread
Answer
D) Run blocking network/disk code on a background thread
Dispatchers.IO is optimised for I/O work off the main thread.
Computer Science MCQ · More Maps and Consuming Web Services over HTTP MCQs · Practise