#include <bits/stdc++.h>   using namespace std;   long long MOD = 998244353;   long long gcd(long long a, long long b) {     long long c;     while (a != 0) {       c = a;       a = b % a;       b = c;     }     return b;   }   signed main() {     cin.tie(0);     ios::sync_with_stdio(false);     long long N;     cin >> N;     vector<long long> A(N);     long long res = 1;     for (long long i = 0; i < N; i++) {       cin >> A[i];     }     map<long long, long long> mp;     map<long long, long long> num;     vector<long long> C;     set<long long> st;     for (long long i = 0; i < N; i++) {       long long X = pow(A[i], 0.25);       X = max((long long)0, X - 3);       while (X * X * X * X < A[i]) X++;       if (X * X * X * X == A[i]) {         mp[X] += 4;         st.insert(X);         continue;       }       X = pow(A[i], 1.0 / 3);       X = max((long long)0, X - 3);       while (X * X * X < A[i]) X++;       if (X * X * X == A[i]) {         mp[X] += 3;         st.insert(X);         continue;       }       X = sqrt(A[i]);       X = max((long long)0, X - 3);       while (X * X < A[i]) X++;       if (X * X == A[i]) {         mp[X] += 2;         st.insert(X);         continue;       }       num[A[i]]++;       if (num[A[i]] == 1) {         C.push_back(A[i]);       }     }     vector<long long> V(C.size(), 0);     for (long long i = 0; i < C.size(); i++) {       for (long long j = i + 1; j < C.size(); j++) {         long long a = gcd(C[i], C[j]);         if (a != 1) {           st.insert(a);           st.insert(C[i] / a);           st.insert(C[j] / a);         }       }     }     vector<long long> sv;     for (auto s : st) {       sv.push_back(s);     }     for (long long i = 0; i < C.size(); i++) {       bool ok = true;       for (long long j = 0; j < sv.size(); j++) {         if (C[i] % sv[j] == 0) {           mp[sv[j]] += num[C[i]];           mp[C[i] / sv[j]] += num[C[i]];           ok = false;           break;         }       }       if (ok) {         long long t = num[C[i]] + 1;         res = (res * t * t) % MOD;       }     }     for (auto m : mp) {       res = (res * (m.second + 1)) % MOD;     }     cout << res << endl;   }   