Created
March 25, 2022 20:32
-
-
Save dgjustice/42558e13b7eb25341bb7d4b304926c57 to your computer and use it in GitHub Desktop.
Prime number fud
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
END { | |
for ( i = 1; i < 100; i++) { | |
arr[i] = i | |
} | |
for (p = 2;p < 49; p++) { | |
for (i = p*2; i < 100; i += p) { | |
delete arr[i] | |
} | |
} | |
for ( i = 1; i < 100; i++) { | |
if (i in arr) { | |
print arr[i] | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment