Skip to content

What is an Armstrong Number? Definition, Examples and List

An Armstrong number equals the sum of its digits raised to the power of the number of digits. See the definition, examples like 153, and a list to 1000.

Category
Tech Basics
On this page

Some numbers hide a secret inside their own digits. Take 153. Split it into its digits 1, 5 and 3, multiply each one by itself three times, and add the answers: 1 + 125 + 27. You get 153 again! Numbers that rebuild themselves like this are called Armstrong numbers. In this guide you’ll learn how they work step by step, see the full list from 1 to 1000, and find out why they are so rare.

What is an Armstrong Number?

An Armstrong number is a number that is equal to the sum of its digits, where each digit is raised to the power of how many digits the number has.

Chalkboard showing 153 = 1 cubed + 5 cubed + 3 cubed and Armstrong numbers 153, 370, 371, 407, 1634, 8208, 9474, 54748
153 = 1³ + 5³ + 3³ = 1 + 125 + 27.

That sounds tricky, so let’s break it down. First, a quick reminder about powers:

  • 52 (“5 squared”) means 5 × 5 = 25.
  • 53 (“5 cubed”) means 5 × 5 × 5 = 125.
  • The small number on top tells you how many times to multiply the number by itself.

For an Armstrong number, the small number on top is always the number of digits. A 3-digit number uses power 3, a 4-digit number uses power 4, and so on. Armstrong numbers are also called narcissistic numbers, because they are “in love with themselves”: they make themselves out of their own digits.

How to Check if a Number is an Armstrong Number

  1. Count the digits. This is your power.
  2. Raise each digit to that power.
  3. Add all the answers together.
  4. Compare with the original number. If they are equal, it’s an Armstrong number.

Example 1: Is 153 an Armstrong number?

StepWorkResult
Step 1Count the digits of 1533 digits, so use power 3
Step 213, 53, 331, 125, 27
Step 31 + 125 + 27153
Step 4153 = 153?Yes

153 is an Armstrong number.

Example 2: Is 123 an Armstrong number?

StepWorkResult
Step 1Count the digits of 1233 digits, so use power 3
Step 213, 23, 331, 8, 27
Step 31 + 8 + 2736
Step 436 = 123?No

123 is not an Armstrong number.

Example 3: A 4-digit number, 1634

StepWorkResult
Step 1Count the digits of 16344 digits, so use power 4
Step 214, 64, 34, 441, 1296, 81, 256
Step 31 + 1296 + 81 + 2561634

1634 is an Armstrong number.

Common mistakeDon’t always use power 3! Many students cube every digit. That only works for 3-digit numbers. For 1634 you must use power 4, because it has 4 digits.

Armstrong Numbers from 1 to 1000

There are only 13 Armstrong numbers from 1 to 1000:

1, 2, 3, 4, 5, 6, 7, 8, 9, 153, 370, 371, 407

NumberCheck
1 to 9Each digit to the power 1 is itself: 71 = 7
15313 + 53 + 33 = 1 + 125 + 27 = 153
37033 + 73 + 03 = 27 + 343 + 0 = 370
37133 + 73 + 13 = 27 + 343 + 1 = 371
40743 + 03 + 73 = 64 + 0 + 343 = 407

Notice that there are no 2-digit Armstrong numbers at all. No number from 10 to 99 equals the sum of the squares of its digits. Some books also count 0 as an Armstrong number, since 01 = 0.

Bigger Armstrong Numbers

DigitsArmstrong numbers
11, 2, 3, 4, 5, 6, 7, 8, 9
2none
3153, 370, 371, 407
41634, 8208, 9474
554748, 92727, 93084

They get rarer and rarer. In our normal number system there are only 88 Armstrong numbers in total, and the biggest one has 39 digits. After that, there are none at all, because the digits of a very long number can never add up to something that big.

Practice Questions

Try these yourself, then click a question to see the answer.

1. Is 370 an Armstrong number?

Yes. 33 + 73 + 03 = 27 + 343 + 0 = 370.

2. Is 125 an Armstrong number?

No. 13 + 23 + 53 = 1 + 8 + 125 = 134, not 125.

3. Which power do you use to check 8208?

Power 4, because 8208 has 4 digits: 84 + 24 + 04 + 84 = 4096 + 16 + 0 + 4096 = 8208.

4. Is 22 an Armstrong number?

No. 22 + 22 = 8. In fact, there are no 2-digit Armstrong numbers.

5. Which two Armstrong numbers are next to each other?

370 and 371.

For Older Students: Check an Armstrong Number with Code

armstrong.py:


def is_armstrong(n):
    digits = str(n)
    power = len(digits)
    return n == sum(int(d) ** power for d in digits)

print([n for n in range(1, 1001) if is_armstrong(n)])

Run it with python3 armstrong.py and it prints the 13 numbers from the list above. In Python, ** means “to the power of”. For complete programs, see how to check an Armstrong number in Python, C, Java and Bash.

FAQ

What is an Armstrong number in simple words?

A number that you can rebuild from its own digits: raise each digit to the power of the number of digits, add them up, and you get the number back. 153 is the most famous example.

Is 153 an Armstrong number?

Yes. 13 + 53 + 33 = 1 + 125 + 27 = 153.

How many Armstrong numbers are there from 1 to 1000?

13: the numbers 1 to 9, plus 153, 370, 371 and 407.

Is 1 an Armstrong number?

Yes. It has 1 digit, and 11 = 1. Every single-digit number is an Armstrong number.

What is another name for an Armstrong number?

A narcissistic number. You may also see “pluperfect digital invariant”.

Conclusion

An Armstrong number equals the sum of its digits, each raised to the power of the number of digits. To check one, count the digits, raise each digit to that power, add them up and compare. From 1 to 1000 there are only 13: the digits 1 to 9 plus 153, 370, 371 and 407. Remember to change the power for longer numbers, and you’ll never get caught out.

Rahul

Rahul Kumar is the founder and chief editor of TecAdmin.net. A Red Hat Certified Engineer (RHCE), he has worked in IT since 2009, with hands-on experience in Linux system administration, DevOps, web hosting, cloud platforms and automation. He started TecAdmin in 2013 to share practical, step-by-step guides, and leads its editorial work with one aim: making technical learning clear and useful for sysadmins, developers and beginners alike.

Leave a Reply

Your email address will not be published. Required fields are marked *


Back to top