Skip to content

Instantly share code, notes, and snippets.

@ferazog
Created April 24, 2021 20:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ferazog/ffc72d6ccf04611ab1d679b08b541dc4 to your computer and use it in GitHub Desktop.
Save ferazog/ffc72d6ccf04611ab1d679b08b541dc4 to your computer and use it in GitHub Desktop.
fun ejecutarCoroutine() {
GlobalScope.launch {
delay(1_000) // Realiza una pausa en la ejecución de un segundo
println("fin de la coroutine")
}
Thread.sleep(2_000) // Debido al delay de un segundo, la brecha de espera aumenta a dos segundos
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment