Intermediate
Kotlin
Q80 / 100
What is kotlinx.coroutines.flow.catch operator used for?
Correct! Well done.
Incorrect.
The correct answer is B) Handling exceptions thrown upstream in a Flow chain, allowing recovery or re-emission
B
Correct Answer
Handling exceptions thrown upstream in a Flow chain, allowing recovery or re-emission
Explanation
flow.catch { e -> emit(defaultValue) } handles exceptions from upstream operators. It does not catch exceptions in downstream operators.
Progress
80/100