Created
November 5, 2019 21:19
-
-
Save kjk/b9fc06c6cd529c4141c349af0580b733 to your computer and use it in GitHub Desktop.
for without test expression
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// :collection Essential Go | |
package main | |
import "fmt" | |
func main() { | |
// :show start | |
i := 0 | |
for ; ; i += 2 { | |
fmt.Printf("i: %d\n", i) | |
if i >= 5 { | |
break | |
} | |
} | |
// :show end | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment