xref: /aosp_15_r20/external/kotlinx.coroutines/kotlinx-coroutines-core/jvm/test/guide/example-cancel-07.kt (revision 7a7160fed73afa6648ef8aa100d4a336fe921d9a)

<lambda>null1 // This file was automatically generated from cancellation-and-timeouts.md by Knit tool. Do not edit.
2 package kotlinx.coroutines.guide.exampleCancel07
3 
4 import kotlinx.coroutines.*
5 
6 fun main() = runBlocking {
7     withTimeout(1300L) {
8         repeat(1000) { i ->
9             println("I'm sleeping $i ...")
10             delay(500L)
11         }
12     }
13 }
14