ccplusplus.com
Learn C, C++ Concepts
Tuesday, February 21, 2012
c program to find prime number in given range
/************************************************************************* * File : find-prime-numbers.c * Author : Saurabh Gupta * Desc : c program to find prime number in given range * Source : http://ccplusplus.com/p/c.html * Created : 10:30 PM Tuesday, February 21, 2012 *************************************************************************/ #include
void main() { int i, nPrime, nUpperLimit, nLowerLimit, n; printf("ENTER THE LOWER LIMIT : "); scanf("%d", &nLowerLimit); printf("ENTER THE UPPER LIMIT : "); scanf("%d", &nUpperLimit); printf("PRIME NUMBERS BETWEEN %d and %d ARE : ", nLowerLimit, nUpperLimit); for(n=nLowerLimit+1; n
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment