You are given an integer *m* as a product of integers *a*<sub class="lower-index">1</sub>, *a*<sub class="lower-index">2</sub>, ... *a*<sub class="lower-index">*n*</sub> <img align="middle" class="tex-formula" src="https://espresso.codeforces.com/cf060eec22f7a6ddd13992efe2ebf6d08fde945a.png" style="max-width: 100.0%;max-height: 100.0%;"/>. Your task is to find the number of distinct decompositions of number *m* into the product of *n* ordered positive integers.

Decomposition into *n* products, given in the input, must also be considered in the answer. As the answer can be very large, print it modulo 1000000007 (10<sup class="upper-index">9</sup> + 7).
The first line contains positive integer *n* (1 ≤ *n* ≤ 500). The second line contains space-separated integers *a*<sub class="lower-index">1</sub>, *a*<sub class="lower-index">2</sub>, ..., *a*<sub class="lower-index">*n*</sub> (1 ≤ *a*<sub class="lower-index">*i*</sub> ≤ 10<sup class="upper-index">9</sup>).
f=[1]*1001
fi=[1]*1001
a=1
b=1
m=10**9+7
from collections import defaultdict
for i in range(1,1001):
    a*=i
    b*=pow(i,m-2,m)
    a%=m
    b%=m
    f[i]=a
    fi[i]=b
d=defaultdict(int)
def factorize(n): 
    count = 0;  
    while ((n % 2 > 0) == False):  
          
        # equivalent to n = n / 2; 
        n >>= 1;  
        count += 1; 
    if (count > 0): 
        d[2]+=count 
    for i in range(3, int(n**0.5) + 1): 
        count = 0; 
        while (n % i == 0):  
            count += 1; 
            n = int(n / i); 
        if (count > 0): 
            d[i]+=count 
        i += 2; 
  
    # if n at the end is a prime number. 
    if (n > 2): 
        d[n]+=1
ans=1
n=int(input())
l=list(map(int,input().split()))
for i in l:
    factorize(i)
for i in d:
    ans*=(f[d[i]+n-1]*fi[n-1]*fi[d[i]])%m
    ans%=m
print(ans)
        

    
