Created
May 10, 2015 23:52
-
-
Save adhithyan15/6d2bc2bd938b5ce37623 to your computer and use it in GitHub Desktop.
While loop in Go
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
package main | |
import "fmt" | |
func main(){ | |
counter := 1 | |
for{ | |
if counter > 10{ | |
break; | |
} | |
fmt.Println("Hello") | |
counter++ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment