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 PYTHON3):

Solution:
import math
for _ in range(int(input())):
    n = int(input())
    p = tuple((n, 1))
    lt  = []
    while n % 2 == 0: 
        lt.append(2) 
        n = n / 2
    for i in range(3,int(math.sqrt(n))+1,2): 
        while n % i== 0: 
            lt.append(i), 
            n = n / i 
    if n > 2: 
        lt.append(int(n)) 
    #print(lt)
    if len(lt)>5:
        print('YES')
        print(lt[0], end =' ')
        print(lt[1]*lt[2], end =' ')
        print(int(p[0]/(lt[0]*lt[1]*lt[2])))
    if len(lt)<3:
        print('NO')
        continue
    if len(lt)==3:
        if (lt[0]==lt[1] or lt[1]==lt[2] or lt[0]==lt[2]):
            print('NO')
            continue
        else:
            print('YES')
            print(lt[0], end=' ')
            print(lt[1], end=' ')
            print(lt[2])
            continue
    if len(lt)==4:
        a=lt[0]
        b=lt[1]*lt[2]
        c=lt[3]
        if a!=b and b!=c and c!=a:
            print('YES')
            print(a, end =' ')
            print(b, end =' ')
            print(c)
            continue
        else:
            print('NO')
            continue
    if len(lt)==5:
        if len(set(lt))==1:
            print('NO')
            continue
        if len(set(lt))==2:
            if lt[0]==lt[1]==lt[2]==lt[3]:
                print('YES')
                print(lt[0], end =' ')
                print(lt[0]**3, end =' ')
                print(lt[-1])
                continue
            elif lt[0]==lt[1]==lt[2] and lt[3]==lt[4]:
                print('YES')
                print(lt[0], lt[1]*lt[2], lt[3]*lt[4])
            elif lt[0]==lt[1]and lt[2]==lt[3]==lt[4]:
                print('YES')
                print(lt[0]**2, lt[2], lt[2]**2)
            else:
                print('YES')
                print(lt[0], end =' ')
                print(lt[1]**3, end =' ')
                print(lt[1])
                continue
        if len(set(lt))==3:
            if lt[0]==lt[1]==lt[2]:
                print('YES')
                print(lt[0]**3, lt[-2], lt[-1])
                continue
            if lt[1]!=lt[0] and lt[2]==lt[1] and lt[3]==lt[4]:
                print("YES")
                print(lt[0], lt[1]*lt[2], lt[3]*lt[4])
                continue
            if lt[0]==lt[1] and lt[3]==lt[4]:
                print('YES')
                print(lt[0]*lt[1], lt[2], lt[3]*lt[4])
                continue
            if lt[0]==lt[1] and lt[3]==lt[2]:
                print("YES")
                print(lt[0]*lt[1], lt[2]*lt[3], lt[4])
            if lt[1]==lt[2]==lt[3]:
                print('YES')
                print(lt[0], lt[1]**3, lt[-1])
                continue
            if lt[-1]==lt[-2]==lt[-3]:
                print('YES')
                print(lt[0], lt[1], lt[2]**3)
                continue
        if len(set(lt))==4:
            print('YES')
            print(lt[0], lt[2]*lt[1], lt[3]*lt[4])
            continue
        if len(set(lt))==5:
            print('YES')
            print(lt[0],lt[1], lt[2]*lt[3]*lt[4])