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
var a = [5, 9, 63, 29, 35, 6, 55, 23] | |
var prime = []; | |
function isPrime(item) { | |
var identifier = item / 2; | |
for (var j = 2; j <= identifier; j++) { | |
if ((item % j) == 0) { // modulous | |
return false; | |
} | |
} |
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
process.stdin.resume(); | |
process.stdin.setEncoding("utf-8"); | |
var stdin_input = []; | |
process.stdin.on("data", function (input) { | |
stdin_input.push(input.replace("\n", "").split(" ").map(Number)); | |
}); | |
process.stdin.on("end", function () { | |
main(stdin_input); |