3427. Equal Numbers

单点时限: 3.0 sec

内存限制: 256 MB

You are given a list of integers . You can perform the following operation: choose some and multiply it by any positive integer.

Your task is to compute the minimum number of different integers that could be on the list after operations for all .

输入格式

The first line of the input contains single integer ().

The second line of the input contains integers ().

输出格式

Output a single line that contains integers. The -th integer should be the minimum possible number of different integers in the list after operations.

样例

Input
6
3 4 1 2 1 2
Output
4 4 3 3 2 2 1

1 人解决,1 人已尝试。

2 份提交通过,共有 2 份提交。

8.9 EMB 奖励。

创建: 2 年,2 月前.

修改: 2 年,2 月前.

最后提交: 2 年,2 月前.

来源: NEERC 2017

题目标签