#include using namespace std; typedef long long ll; int gcd(int x, int y) { if (y == 0) return x; return gcd(y, x % y); } int main() { int N; scanf("%d", &N); vector A(N); for (int i = 0; i < N; ++i) scanf("%d", &A[i]); int g = A[0]; for (int i = 1; i < N; ++i) g = gcd(g, A[i]); int ans = 0; for (int i = 0; i < N; ++i) ans += A[i] / g; printf("%d\n", ans); return 0; }