← All problemsSign in

Armstrong Numbers

You are given the task of writing a program to tell whether a number is an armstrong number or not. A number is called an armstrong number if the sum of each of its digits to the power of its number of digits is eual to the number. Eg- take the number 153. It has three digits. So, we do this: 1^3 + 5^3 + 3^3 which is equal to 153. ###Input: - First line contains an integer $N$.

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start