import sys

# from collections import deque
# 26
input = lambda: sys.stdin.readline().strip()
ipnut = input
# def ch(a):
#     return a**0.5==int(a**0.5)
for i in range(int(input())):
    # n = int(ipnut())
    n, l, r = map(int, input().split())
    an = ['1', '2']
    ans = []
    lo = l
    r+=1
    if l < 3:
        ans += an[l - 3:]
        l = 3
    k = (l - 3) // 4
    if l == 3 + 4 * k + 1:
        ans.append(str(k + 3))
        ans.append(str(k + 2))
        ans.append(str(k + 3))
    elif l == 3 + 4 * k + 2:
        ans.append(str(k + 2))
        ans.append(str(k + 3))
    elif l == 5 + 4 * k:
        ans.append(str(k + 3))
    else:
        k -= 1
    k += 1
    while len(ans) <= r - lo+6:
        ans.append('1')
        ans.append(str(k + 3))
        ans.append(str(k + 2))
        ans.append(str(k + 3))
        k += 1
    print(' '.join(ans[:r - lo]))
