H. Fady mesh fady
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Fady was playing "Skrew sa7b sa7bo" was his friends at the college. Suddenly, Came up to his mind an interesting Math problem. You are given an integer $$$N$$$ and $$$N$$$ positive integers $$$A_1, A_2, ..., A_N$$$. You need to choose $$$N$$$ positive integers $$$B_1, B_2, ..., B_N$$$ such that for all $$$(i \lt j)$$$: $$$A_i B_i = A_j B_j$$$ Among all such choices. Can you help Fady find the minimum possible value of: $$$B_1 + B_2 + ... + B_N$$$? Print the minimum value.

Input

The first line contains an integer $$$N$$$ $$$(1 \le N \le 2 * 10^5)$$$. The second line contains $$$N$$$ integers $$$A_1, A_2, ..., A_N$$$ $$$(1 \le A_i \le 20)$$$.

Output

Print one integer — the minimum possible value of $$$B_1 + B_2 + ... + B_N$$$.

Example
Input
6
1 2 3 4 5 6
Output
147