Created
February 1, 2016 17:08
-
-
Save nilskoppelmann/7c0852c4e1ea98b4df16 to your computer and use it in GitHub Desktop.
The 30-day minimalism challenge in Go
This file contains hidden or 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() { | |
helper := 0 | |
out := 0 | |
for i := 1; i <= 30; i++ { | |
if i == 1 { | |
helper = i | |
} else { | |
helper++ | |
} | |
out += helper | |
} | |
fmt.Println(out) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment