0
A program for armstrong number
3 Respostas
+ 12
Algo :
1. Declare variables.
2. Enter a number. // n=153
3. Store it in another variable. // temp=n
4. Reverse the entered number:
while(n!=0)
{
digit=n%10;
rev=rev+(digit*digit*digit);
n=n/10;
}
5. if reverse of number == temp then Armstrong
else
not Armstrong
0
thanks😊😊😊😊