ccplusplus.com
Learn C, C++ Concepts
Friday, January 13, 2012
perfect number from 1 to 1000 in c
/*********************************************************************** * File : print-perfect-number.c * Author : Saurabh Gupta * Desc : perfect number from 1 to 1000 in c * Source : http://ccplusplus/p/c.html * Created : PM 06:37 13 January 2012 * Note : ************************************************************************/ #include
int main() { int n, i, sum; printf("Perfect numbers from 1 to 1000 are: "); for(n=1;n<=1000;n++){ i=1; sum = 0; while(i
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment