A number of n digit is called Armstrong number if sum of the power of n of its digits is equal to the number itself.
For example a number of three digits integer is an Armstrong number if the sum of the cubes of its digits is equal to the number itself. 153 is an Armstrong number since 1*1*1 + 5*5*5 + 3*3*3 = 371.
For example a number of three digits integer is an Armstrong number if the sum of the cubes of its digits is equal to the number itself. 153 is an Armstrong number since 1*1*1 + 5*5*5 + 3*3*3 = 371.
Most Related:
PROBLEM STATEMENT
Write a program in C to find the Armstrong Number between intervals.
SOURCE CODE
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | #include |
OUTPUT
Related Topics
- C program to store information of n student using structure
- C program to find the length of a string without strlen( ) function
- C program to check whether a certain number is Armstrong or not
- C Program to Check Whether a Number is Palindrome or Not
- C Program to display the Fibonacci Series up-to n number of terms
- C Program to display the Fibonacci Series up-to a certain number
- C program to find the factorial of a number
- C Program to Find Prime Numbers Between Intervals Using Functions.
- C program: perfect or not checking
- C program to identify a number as even or odd
- C Program to print Hello World
No comments:
Post a Comment