Javatpoint Logo
Javatpoint Logo

Armstrong Number in Java

Let's write a java program to check whether the given number is armstrong number or not.

Armstrong Number in Java: A positive number is called armstrong number if it is equal to the sum of cubes of its digits for example 0, 1, 153, 370, 371, 407 etc.

Let's try to understand why 153 is an Armstrong number.

Let's try to understand why 371 is an Armstrong number.

Let's see the java program to check Armstrong Number.

Output:

armstrong number
Next TopicJava Programs


Please Share

facebook twitter google plus pinterest

Learn Latest Tutorials


Preparation


Trending Technologies


B.Tech / MCA