#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    long long n, l, r;
    scanf("%lld%lld%lld", &n, &l, &r);
    int flag = 0;
    long long now = l >> 1;
    if (l % 2 == 0) {
      flag = 2;
    } else {
      flag = 1;
    }
    long long head = -1;
    for (int i = 1; i < n; ++i) {
      now -= n - i;
      if (now < 0) {
        head = i;
        now += n - i;
        now = head + 1 + now;
        break;
      }
    }
    if (head == -1) {
      printf("1\n");
      continue;
    }
    int flag1 = 0;
    int sum = l - r + 1;
    while (sum--) {
      if (flag == 1) {
        if (head == n) {
          flag1 = 1;
          break;
        }
        printf("%lld ", head);
        flag = 2;
      } else if (flag == 2) {
        printf("%lld ", now);
        flag = 1;
        if (now == n) {
          head += 1;
          now = head + 1;
        } else {
          now++;
        }
      }
    }
    if (flag1) {
      printf("1\n");
      continue;
    }
    printf("\n");
  }
  return 0;
}
