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;
long long gcd(long long a, long long b) {
  for (; b; a %= b, swap(a, b))
    ;
  return a;
}
vector<long long> pr;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0), cout.tie(0);
  pr.push_back(2);
  for (long long i = 3; i * i <= 1000000000; i++) {
    bool flag = false;
    for (int j = 0; j < pr.size() && pr[j] * pr[j] <= i; j++) {
      if (i % pr[j] == 0) {
        flag = true;
        break;
      }
    }
    if (!flag) pr.push_back(i);
  }
  int t;
  cin >> t;
  while (t--) {
    map<long long, int> mp;
    long long n;
    cin >> n;
    for (int i = 0; i < pr.size(); i++) {
      while (n % pr[i] == 0) {
        n /= pr[i];
        mp[pr[i]]++;
      }
    }
    if (n != 1) mp[n]++;
    if (mp.size() >= 3) {
      cout << "YES\n";
      long long tmp = 1;
      int cnt = 0;
      for (auto &it : mp) {
        if (cnt < 3) tmp = 1;
        for (int i = 0; i < it.second; i++) tmp *= it.first;
        if (cnt < 2) {
          cout << tmp << ' ';
        }
        cnt++;
      }
      cout << tmp << ' ';
      cout << '\n';
    } else if (mp.size() == 2) {
      int twoCnt = 0;
      bool flag = false;
      for (auto &it : mp) {
        if (it.second >= 3)
          flag = true;
        else if (it.second == 2)
          twoCnt++;
      }
      if (!flag) {
        if (twoCnt == 2) {
          cout << "YES\n";
          long long f1 = (*mp.begin()).first;
          long long f2 = (*++mp.begin()).first;
          cout << f1 << ' ' << f2 << ' ' << f1 * f2 << '\n';
        } else
          cout << "NO\n";
        continue;
      }
      cout << "YES\n";
      bool hasPrinted = false;
      for (auto &it : mp) {
        if (it.second >= 3 && !hasPrinted) {
          cout << it.first << ' ';
          long long tmp = 1;
          for (int i = 0; i < it.second - 1; i++) tmp *= it.first;
          cout << tmp << ' ';
          hasPrinted = true;
        } else {
          long long tmp = 1;
          for (int i = 0; i < it.second; i++) tmp *= it.first;
          cout << tmp << ' ';
        }
      }
      cout << '\n';
    } else if (mp.size() == 1) {
      auto it = *mp.begin();
      if (it.second < 6) {
        cout << "NO\n";
        continue;
      }
      cout << "YES\n";
      long long num = it.first;
      cout << num << ' ' << num * num << ' ';
      long long tmp = 1;
      for (int i = 0; i < it.second - 3; i++) tmp *= it.first;
      cout << tmp << '\n';
    } else
      cout << "NO\n";
  }
}