HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Volumes > Functions > problem:


160. 50571 - Armstrong Numbers - 2

Guest
• Discussion of problem (1)

Volume problems

• 50305 - John's Tasks
• 002. 50428 - Three Times
• 010. 50582 - Number of digits
• 035. 50467 - Random Numbers
• 062. 50390 - Total Salary Paid
• 100. 50397 - The Number of Points ...
• 135. 50572 - Palindromic Numbers
• 145. 50586 - Prime Palindromes
• 160. 50571 - Armstrong Numbe...
• 50315 - Pig Latin
• 50353 - Cube of the Largest number
• 50296 - Total Discount Rate
• 50559 - Prime Factors of a Number
• 040. 50354 - Intersecting Rectangles
• 060. 50727 - Fibonacci Numbers
• 061. 50733 - The Highest Average
• 076. 50289 - Monthly Allowance

Feedback

If you notice incorrect translations in Contester, please let author know.

Time limit 2000/4000/4000/4000 ms. Memory limit 65000/65000/65000/65000 Kb.
Prepared by Ibrahim Mesecan. Difficulty Alpha

Armstrong Numbers

Shqip

Number 153 has 3 digits and if you take the 3rd power of every digit and calculate the sum of them, you will have the same number again.
153 = 13 + 53 + 33
     = 1 + 125 + 27 = 153
Thus for 1634 you should take the fourth powers of every digit (because the number has 4 digits) and calculate the sum. If the sum is equal to the number itself then we say that this number is an Armstrong Number.

Input specification
There will be two numbers between 1 < n < m ≤ 100000.
Output specification
Between the given numbers, show the Armstrong Numbers (if there is any). If there are several numbers show them separated by spaces. Otherwise print "No" (without double quotations) followed by an endline.

Input I Input II
100 200 1000 2000
Output 1 Output 2
153
1634

Для отправки решений необходимо выполнить вход.

www.contester.ru