#include <bits/stdc++.h>
using namespace std;
long long a[400001];
long long G(long long a, long long b) {
  if (b == 0) return a;
  return G(b, a % b);
}
int main() {
  long long n;
  cin >> n;
  for (long long i = 0; i < n; i++) {
    cin >> a[i];
  }
  long long gcd = a[0];
  for (long long i = 1; i < n; i++) {
    gcd = G(gcd, a[i]);
  }
  long long count = 0;
  for (long long i = 1; i * i <= gcd; i++) {
    if (gcd % i == 0) {
      ++count;
      if (i != gcd / i) {
        ++count;
      }
    }
  }
  cout << count << endl;
  return 0;
}
