Sunday, June 6, 2010

Check the given number is armstrong number or not using c program




Code 1:

1. Warp
to check a number is Armstrong

2. C program to check whether a number is Armstrong or not

3. Simple
c program for Armstrong number

4. Armstrong
number in c with output



#include

int main(){

int num,r,sum=0,temp;



printf("Enter a
number: ");

scanf("%d",&num);



temp=num;

while(num!=0){

r=num%10;

num=num/10;

No comments:

Post a Comment