Let's assume that 
 -  *v*(*n*) is the largest prime number, that does not exceed *n*;-  *u*(*n*) is the smallest prime number strictly greater than *n*. 
Find <img align="middle" class="tex-formula" src="https://espresso.codeforces.com/9efda33382293068ce21371b950297a1d3ac3212.png" style="max-width: 100.0%;max-height: 100.0%;"/>.
The first line contains integer *t* (1 ≤ *t* ≤ 500) — the number of testscases. 

Each of the following *t* lines of the input contains integer *n* (2 ≤ *n* ≤ 10<sup class="upper-index">9</sup>).
from math import gcd
def prime(n):
    if(n<2):
        return 0
    
    i=2
    while i**2<=n:
        if(n%i==0):
            return 0
        i+=1

    return 1




t=int(input())

for i in range(0,t):
    n=int(input())
    L=n
    M=n+1
    if(prime(M)):
        print(str(M-2)+'/'+str(2*M))
        continue
    
    while not prime(M):
        M+=1
    while not prime(L):
        L-=1
    a=L*M-2*M+2*(n-L+1)
    b=2*M*L
    p=gcd(a,b)
    a//=p
    b//=p
    print(str(a)+'/'+str(b))