Mult!

아직 제출이 없습니다시간 제한1초메모리 제한1024 MB

문제

Nora Mainder has a game she plays with her students to help them learn multiplication. She calls out a sequence of numbers and the students have to determine when she names a whole number multiple of the first number. When a student recognizes such a multiple, he or she must call out “Mult!”, ending this round of the game. Then a new round begins with a new initial number. Fortunately her students are very bright and never fail to recognize a multiple, so they all cry out at once—a “multitude” of shouts.

For instance, if she calls out “88, 33, 1212, 66, 2424,” her students all yell “Mult!” when she reaches 2424 because it is a multiple of the first number, 88. If she begins a second round of the game with the sequence “1414, 1212, 99, 7070,” the class will call out “Mult!” when she reaches 7070, a multiple of the first number, 1414.

Given a sequence of numbers called out by Nora during several rounds of the game, identify which numbers ought to produce a shout of “Mult!”

입력

The first line of input contains an integer nn, 2 n1,0002 ≤ n ≤ 1\\,000, the length of the number sequence. The following nn lines contains the sequence, one number per line. All numbers in the sequence are positive integers less than or equal to 100100. The sequence is guaranteed to contain at least one complete round of the game (but may end with an incomplete round).

출력

Print all of the sequence elements that will cause the class to shout “Mult!” Each value should be printed on a separate line.