Score : $300$ points
Given are $N$ integers between $2$ and $50$ (inclusive): $X_1, X_2, \cdots, X_N$. Find the minimum positive integer $Y$ that satisfies the following for every $i = 1, 2, \cdots, N$:
Input is given from Standard Input in the following format:
$N$ $X_1$ $X_2$ $\ldots$ $X_N$
Print the minimum positive integer that satisfies the condition.
2 4 3
6
Being not coprime with $4$ requires being even, and being not coprime with $3$ requires being a multiple of $3$.
1 47
47
7 3 4 6 7 8 9 10
42