#include <bits/stdc++.h>
using namespace std;
int Mod = 1000000007;
map<int, int> M;
map<int, int>::iterator it;
long long int DP[2][17507];
int main() {
  int i, j, k, l, m, n, x, y, z, a, b, c, r;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    scanf("%d", &x);
    y = x;
    for (j = 2; j * j <= x; j++) {
      c = 0;
      while (y % j == 0) {
        c++;
        y /= j;
      }
      if (c != 0) M[j] += c;
    }
    if (y != 1) M[y]++;
  }
  c = 0;
  for (i = 0; i <= 17500; i++) DP[c][i] = 1;
  for (i = 2; i <= n; i++) {
    for (j = 1; j <= 17500; j++) DP[c][j] = (DP[c][j] + DP[c][j - 1]) % Mod;
    for (j = 0; j <= 17500; j++) DP[1 - c][j] = DP[c][j];
    c = 1 - c;
  }
  long long int ans = 1;
  for (it = M.begin(); it != M.end(); ++it) {
    ans = (ans * DP[c][it->second]) % Mod;
  }
  printf("%lld\n", ans);
  return 0;
}
