Last active
June 21, 2017 10:33
-
-
Save aomnes/2ed74761babdfd716dc5d6be4e483eee to your computer and use it in GitHub Desktop.
Test Stage
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() { | |
var count int = 0 | |
s := make([]bool, 120) | |
for i := 1; i <= 120; i++ { | |
for j := 0; j < 120; j += i { | |
s[j] = !s[j] | |
} | |
} | |
for i := 0; i < 120; i++ { | |
fmt.Println(i, s[i]) | |
if s[i] == true { | |
count++ | |
} | |
} | |
fmt.Println("Count ==> ", count) | |
//Affiche 10 Turn On. | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment