#Lutece1053. GCD
GCD
Migrated from Lutece 1053 GCD
All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.
Description
There is a sequence which has elments. Each element of the sequence is ranged in . Now Alice is wondering for each , how many solutions for she to choose elements from the sequence so that the greatest common divisor of them is no more than .
As is known to everyone of you, Bob loves Alice very much. Could you tell Bob the answers to help Bob leave a good impression on Alice.
Input
The first line contains an integer , indicating the number of the elements in the sequence.
The next line contains integers , indicating the element in the sequence.
It is guaranteed that .
Output
Print lines. For each , the line contains the number of solutions for Alice to choose elements from the sequence, so that the greatest common divisor of them is no more than . The answer be moduled by 1000000007.
Samples
3
2 2 3
2
2
Resources
The 13th UESTC Programming Contest Final