[BOJ 6966] Cross-Number Puzzle

View as PDF

Submit solution

Points: 1
Time limit: 1.0s
Memory limit: 128M

Problem types
Allowed languages
Assembly, Awk, C, C++, Java, Pascal, Perl, Python, Sed, Text

Write a program to print:</p>

  1. The perfect numbers between $1\,000$ and $9\,999$ inclusive. A perfect number is a positive integer which is equal to the sum of its proper divisors. A proper divisor is any divisor less than the number itself. For example, $6$ is a perfect number since $1 + 2 + 3 = 6$.
  2. All integers between $100$ and $999$ inclusive which are equal to the sum of the cubes of their digits.
## 입력 형식

There is no input.

출력 형식

All the perfect numbers between $1\,000$ and $9\,999$ inclusive on one line, followed by all integers between $100$ and $999$ inclusive which are equal to the sum of the cubes of their digits on one line.


Comments

There are no comments at the moment.