Problem: You are given one integer number n. Find three distinct integers a, b, c such that 2 ≤ a, b, c and a ⋅ b ⋅ c = n or say that it is impossible to do it.

If there are several answers, you can print any.

You have to answer t independent test cases.

Input

The first line of the input contains one integer t (1 ≤ t ≤ 100) — the number of test cases.

The next n lines describe test cases. The i-th test case is given on a new line as one integer n (2 ≤ n ≤ 10^9).

Output

For each test case, print the answer on it. Print "NO" if it is impossible to represent n as a ⋅ b ⋅ c for some distinct integers a, b, c such that 2 ≤ a, b, c.

Otherwise, print "YES" and any possible such representation.

Example

Input


5
64
32
97
2
12345


Output


YES
2 4 8 
NO
NO
NO
YES
3 5 823 

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
void add(long long int& a, long long int b) {
  a += b;
  while (a >= mod) a -= mod;
  while (a < 0) a += mod;
}
void mul(long long int& a, long long int b) {
  a *= b;
  while (a >= mod) a -= mod;
  while (a < 0) a += mod;
}
long long int binexpomodulo(long long int x, long long int y) {
  long long int res = 1;
  x %= mod;
  if (!x) return 0;
  while (y) {
    if (y & 1) {
      mul(res, x);
    }
    mul(x, x);
    y >>= 1;
  }
  return res;
}
long long int nCrInOr(long long int n, long long int r) {
  long long int res = 1;
  if (r > n - r) r = n - r;
  long long int rin = 1;
  for (long long int i = 1; i <= r; i++) rin = (rin * i) % mod;
  rin = binexpomodulo(rin, mod - 2);
  for (long long int i = 1; i <= r; i++) res = (res * (n - i + 1)) % mod;
  res = (res * rin) % mod;
  return res;
}
int main() {
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    vector<pair<int, int>> fac;
    for (int i = 2; i * i <= n; i++) {
      if (n % i == 0) {
        int c = 0;
        while (n % i == 0) {
          c++;
          n /= i;
        }
        fac.push_back({i, c});
      }
    }
    if (n >= 2) fac.push_back({n, 1});
    if (fac.size() == 1) {
      if (fac[0].second >= 6) {
        int f = fac[0].first;
        int p = fac[0].second;
        cout << "YES" << endl;
        cout << f << " " << f * f << " " << (int)(pow(f, p - 3) + 0.5) << endl;
      } else
        cout << "NO" << endl;
    } else if (fac.size() == 2) {
      if (fac[0].second > 2 || fac[1].second > 2) {
        cout << "YES" << endl;
        if (fac[0].second > 2) {
          int f = fac[0].first;
          int p = fac[0].second;
          cout << f << " " << (int)(pow(f, p - 1) + 0.5) << " ";
          cout << (int)(pow(fac[1].first, fac[1].second) + 0.5) << endl;
        } else {
          int f = fac[1].first;
          int p = fac[1].second;
          cout << f << " " << (int)(pow(f, p - 1) + 0.5) << " ";
          cout << (int)(pow(fac[0].first, fac[0].second) + 0.5) << endl;
        }
      } else if (fac[0].second == 2 && fac[1].second == 2) {
        cout << "YES" << endl;
        cout << fac[0].first << " " << fac[1].first << " "
             << fac[0].first * fac[1].first << endl;
      } else {
        cout << "NO" << endl;
      }
    } else {
      cout << "YES" << endl;
      cout << (int)(pow(fac[0].first, fac[0].second) + 0.5) << " "
           << (int)(pow(fac[1].first, fac[1].second) + 0.5) << " ";
      int final = 1;
      for (int i = 2; i < fac.size(); i++)
        final *= (int)(pow(fac[i].first, fac[i].second) + 0.5);
      cout << final << endl;
    }
  }
  return 0;
}