go (break goto continue)

时间:2021-01-24 16:57:48
package main

import (
"fmt"
) func main() {
LABEL1:
for {
for i := ; i < ; i++ {
if i > {
break LABEL1
}
}
}
fmt.Println("ok")
}
package main

import (
"fmt"
) func main() { for {
for i := ; i < ; i++ {
if i > {
goto LABEL1
}
}
}
LABEL1:
fmt.Println("ok")
}
package main

import (
"fmt"
) func main() {
LABEL1:
for i := ; i < ; i++ {
fmt.Println(i)
for {
continue LABEL1
}
} fmt.Println("ok")
}