import collections, math, bisect

local = False
if local:
    file = open("input.txt", "r")
    import time

def inp():
    if local:
        return file.readline().rstrip()
    else:
        return input().rstrip()

def ints():
    return [int(_) for _ in inp().split()]


if local:
    start=time.time()


t = int(inp())

for _ in range(1,t+1):
    n, l, r = ints()

    if l==1:
        edge = 1
        vert = 1
    else:
        edge = 2
        vert = 2

        while edge<l:
            edge+=2*(vert-1)
            vert+=1

            if edge>l:
                vert-=1
                edge-=2*(vert-1)
                break

    
    ans = []
    while edge<=r:
        if vert==1:
            if edge>=l:
                ans.append(1)
            vert=2
            edge=2
            continue

        for v in range(vert-1,0,-1):
            if edge>=l:
                ans.append(vert)
            edge+=1
            if edge>r:
                break
            if edge>=l:
                ans.append(v)
            edge+=1
            if edge>r:
                break

        vert+=1

    print(" ".join([str(_) for _ in ans]))

if local:
    fin = (time.time()-start)*1000
    print("{:.2f}".format(fin) + "ms")



