Problem: Chester Bennington, being a skinny kid as we all know, is always bullied since he was a child. This time its just unacceptable. Mike Shinoda, the second vocalist to his band, tried to bully him. Chester was never a bright student and Mike, being a high school graduate, gave him a tough mathematical problem. He gave Chester a number N. His task is to find all the prime numbers under N(inclusive) which can be written as the sum of two primes and list them.

Help Chester so that this time he is not bullied....... Again !!!

Input: First line contains t, the number of test cases. t lines follow after that which contain an integer N.

Output: For each test case, you have to print all the prime numbers that meet the above mentioned condition in a single line in a space separated format. For each test-case use a new line.

Constraints:

1 ≤ t ≤ 100

1 ≤ N ≤ 10000

Note: 1 and 0 are not considered Primes

Problem Setter: Rohit Mishra

SAMPLE INPUT
3
7
17
29

SAMPLE OUTPUT
5 7
5 7 13
5 7 13 19

Explanation

Consider test case - 2
N=17
Prime Numbers under 17 are 2,3,5,7,11,13,17
Output is 5,7,13

As 1+10 = 2+9 = 3+8 = 4+7 = 5+6 = 11
None of the above mentioned pairs meets the required criteria.
Same is the case with the other numbers which are not mentioned in the output.

Solution (in PYTHON):

Solution:
def isprime(x):
    X = int((x**0.5))+1
    for i in xrange(2,X):
        if(x%i==0):
            return False
    return True
def op(n,ref):
    p=[2]
    for i in xrange(3,n):
        if(isprime(i)):
            ref[i]=1
            p+=[i]
    return p
def prog():
    t = input()
    T=t
    nums=[]
    while(t):
        nums+=[input()]
        t-=1
    mn = max(nums)
    ref=[0]*(mn+1)
    ref[2]=1
    pr=op(mn,ref)
    l = len(pr)
    dr=[]
    for i in xrange(0,l):
        for j in xrange(i,l):
            x = pr[i]
            y = pr[j]
            if(x+y<=mn):
                if(ref[x+y]==1):
                    dr+=[x+y]
    for i in nums:
        for j in dr:
            if(j>i):
                break
            print j,
        print '\n',
prog()