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>).
def ras(i):
    j=2
    x=i
    y=i
    c=0
    while(i>=2):
        while(x/j>=j):
            if(x%j!=0):
             j=j+1
            else:
             x=x-1
             j=2
        a=x
        j=2
        while(y/j>=j):
            if(y%j!=0):
             j=j+1
             if(y==i):
                 y=y+1
                 j=2
            else:
             y=y+1
             j=2
        b=y
        if(i==2):
            a=2
            b=3
        if(i==3):
            a=3
            b=5
        

        c=c+1/(a*b)
        i=i-1
                
    
    
        
        
            

        
    return(c)

a=[]
t=int(input())
for i in range(t):
    i=int(input())
    r=ras(i)
    a.append(r)
print(*a,sep="\n")

        
    
    
    
    

    
    
    


























