Skip to content

Latest commit

 

History

History

082-armstrong-numbers

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Armstrong Numbers

Challenge Description:

An Armstrong number is an n-digit number that is equal to the sum of the n'th powers of its digits. Determine if the input numbers are Armstrong numbers.

Input sample:

Your program should accept as its first argument a path to a filename. Each line in this file has a positive integer. E.g.

6
153
351

Output sample:

Print out True/False if the number is an Armstrong number or not. E.g.

True
True
False