📘return
for n in 1...10 {
if n == 3 { return } // ⛔ error
// ^^^^^^
// ⛔ error: return invalid outside of a func
}Last updated
for n in 1...10 {
if n == 3 { return } // ⛔ error
// ^^^^^^
// ⛔ error: return invalid outside of a func
}Last updated