#include <bits/stdc++.h>
using namespace std;
const int maxn = 4e5 + 7;
int n, ans;
long long a, b;
long long gcd(long long a, long long b) { return b == 0 ? a : gcd(b, a % b); }
int main() {
  cin >> n;
  cin >> a;
  b = gcd(0, a);
  for (int i = 2; i <= n; i++) cin >> a, b = gcd(a, b);
  for (int i = 1; i <= sqrt(b); i++) {
    if (b % i == 0) {
      ans++;
      if ((long long)i * i != b) ans++;
    }
  }
  printf("%d\n", ans);
  return 0;
}
