<@U3Z9W7YTU> You cannot use return with label as d...
# getting-started
g
@victortong You cannot use return with label as direct replacement for goto. return with label support only return from an outer function (you can use label to mark lambda or loop) I’m not sure about your real case, but I think you must refactor your code, maybe easest way just move what you want to printAgain@ to separate function or use recursion, something like:
Copy code
fun foo() {

    println("print again”)

    for (i in 1..50) {
        print(i)
        //WARNING: Your case is actually infinite loop, so my example is only to show how to use recursion here, please add more real world sample, I’m just not sure what you want to achieve 
        if (i == 24) {
            foo()
            return
        }
        if (i == 25)
            break

    }
}