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 
import functools
import heapq as hp
import collections
import bisect
import math


def unpack(func=int):
    return map(func, input().split())


def l_unpack(func=int):
    """list unpack"""
    return list(map(func, input().split()))


def s_unpack(func=int, rev=False):
    """sorted list unpack"""
    return sorted(map(func, input().split()), reverse=rev)


def ml_unpack(n):  # multiple line unpack
    """list of n integers passed on n line, one on each"""
    return [int(input()) for i in range(n)]


def range_n():
    return range(int(input()))


def getint():
    return int(input())


def counter(a):
    d = {}
    for x in a:
        if x in d:
            d[x] += 1
        else:
            d[x] = 1
    return d


def main():
    for _ in range_n():
        n = getint()
        d = {}
        i = 2
        while i * i <= n:
            if i>n:
                break
            if not n % i:
                d[i] = 0
            while not n % i:
                n //= i
                d[i] += 1
            if len(d) == 2:
                break
            i += 1
        if n > 1:
            d[n] = 1
        key = list(d)
        # print(d)
        if len(key) == 1 and d[key[0]] > 5:
            k = key[0]
            a, b, c = k, k ** 2, k ** (d[k] - 3)
        elif len(key) == 2:
            a, b = key
            if d[a] > 2:
                b = b ** d[b]
                c = a ** (d[a] - 1)
            elif d[b] > 2:
                a = a ** d[a]
                c = b ** (d[b] - 1)
            elif d[a] == d[b] == 2:
                c = a * b
            else:
                print('NO')
                continue
        elif len(key) == 3:
            a, b, c = key
            a, b, c = a ** d[a], b ** d[b], c ** d[c]
        else:
            print('NO')
            continue
        print('YES')
        print(a, b, c)


main()
