Implimented listPrimes