-->
当前位置:首页 > 题库

PROGRAMMING:Print complete

Luz5年前 (2021-05-10)题库479
###Task description
```
If a number is exactly equal to the sum of its factors, the number becomes "perfect". For example, the factors of 6 are 1, 2 and 3, and 6 = 1 + 2 + 3, so 6 is "perfect". The program prints out all the completions in the interval [a, b], and outputs all the factors in the following format:
6 its factors are 1,2,3
```
###Input format:
```
Two positive integers a and B in a row (both numbers are greater than 5 and a < b)
```
###Output format:
```
Output all completions within 1000 and their factors, one for each line. If not, output: not found!
```
###Input example:
```in
6 100
```
###Output example:
```out
6 its factors are 1,2,3
28 its factors are 1,2,4,7,14
```
###Input example:
```in
100 200
```
###Output example:
```out
Not found!
```
###Title Source
Note: this topic is adapted from openjudge website http://sdau.openjudge.cn/c/009/







answer:If there is no answer, please comment