#t159. 求正整数 2 和 n 之间的完全数

求正整数 2 和 n 之间的完全数

Perfect Numbers Between 2 and n

Problem Background

Special for beginners, ^_^

Problem Description

Find all perfect numbers strictly between 22 and nn (2<n≤10002<n\le 1000), one per line.

A perfect number is a natural number whose proper divisors sum to itself, e.g. 6=1+2+36=1+2+3.

Input Format

The input gives nn.

Output Format

One number per line, in increasing order.

Sample Input

7

Sample Output

6

Constraints

1s, 1024KiB for each test case.