#include /* The prime factors of 13195 are 5, 7, 13 and 29. What is the largest prime factor of the number 600851475143 ? https://projecteuler.net/problem=3 */ int main(int argc,char**argv) { long primes[10000]; int primeCount=1; long primeVal=3; long highestPrime=1; primes[0]=2; long startingNumb=600851475143; label: while (startingNumb>1) { //find the next prime. char isPrime=1; for (int i=0;i