ABOUT PRIME NUMBER
A prime number (or a prime) is a natural number greater than 1 that cannot be formed by multiplying two smaller natural numbers. A natural number greater than 1 that is not prime is called a composite number. For example, 5 is prime because the only ways of writing it as a product, 1 × 5 or 5 × 1, involve 5 itself. However, 6 is composite because it is the product of two numbers (2 × 3) that are both smaller than 6. Primes are central in number theory because of the fundamental theorem of arithmetic: every natural number greater than 1 is either a prime itself or can be factorized as a product of primes that is unique up to their order.
TYPICAL SOURCE CODE RELATED
This code is worked on from http://notmyfaultsblog.blogspot.in/2010/06/project-euler-problem-7-in-c.html
Modified a little for standards by Jeffrin Jose T firstname.lastname@example.org
By listing the first six prime numbers: 2, 3, 5, 7, 11, and 13, we can see that the 6th prime is 13.
What is the 10 001st prime number?
int isPrime(int test)
int calculateTo = (int) sqrt(test);
for(i = 3; i<=calculateTo; i+=2)
for(i=3 ; ; i+=2)
if( isPrime(i) )
TYPICAL OUTPUT SESSION RELATED
$gcc -lm tpn.c -o tpn