#t255. 大整数的因子

大整数的因子

Factors of a Large Integer

Problem Background

Special for beginners, ^_^

Problem Description

Given a positive integer kk satisfying 2≤k≤92 \le k \le 9, and a non-negative decimal integer cc whose length is at most 3030 digits, find all values of kk that divide cc.

Input Format

One line containing a non-negative integer cc, where the number of digits of cc is at most 3030.

Output Format

If there exists a kk such that c % k == 0, output all such kk in increasing order, separated by a single space. If no such kk exists, output none.

Sample Input

30

Sample Output

2 3 5 6

Constraints

Time limit: 1s, memory limit: 1024KiB for each test case.