#include <bits/stdc++.h>
using namespace std;
long long x[15005][505], mod = 1e9 + 7;
map<int, int> c;
set<int> all;
int main() {
  for (int i = 1; i <= 500; i++) x[1][i] = i;
  for (long long i = 2; i <= 15000; i++) {
    x[i][1] = 1;
    for (long long j = 2; j <= 500; j++) {
      x[i][j] = x[i][j - 1] + x[i - 1][j];
      while (x[i][j] >= mod) x[i][j] -= mod;
    }
  }
  int n;
  cin >> n;
  long long v;
  for (int k = 1; k <= n; k++) {
    cin >> v;
    for (int i = 2; i * i <= v; i++) {
      while (v % i == 0) {
        c[i]++;
        v /= i;
        all.insert(i);
      }
    }
    if (v != 1) {
      c[v]++;
      all.insert(v);
    }
  }
  long long ans = 1;
  for (set<int>::iterator it = all.begin(); it != all.end(); it++) {
    v = c[*it];
    ans *= x[v][n];
    ans %= mod;
  }
  cout << ans << endl;
}
