Little node.js script that writes the first 100 prime numbers to a file
Probably not the best algorithm as I'm not using the sieve of Atkin or the sieve of Eratosthenes but it could be worse :-)
To execute node primes.js
The created file is called primes.txt