#include <bits/stdc++.h>
using namespace std;
vector<int> s;
int n;
int solve(long long x) {
  if (x > s[n - 1]) {
    return 1;
  }
  auto id = lower_bound(s.begin() + 1, s.end(), x) - s.begin();
  int pos = x - s[id - 1];
  if (pos & 1) {
    return id;
  } else {
    return (pos >> 1) + id;
  }
}
int main() {
  int tt;
  cin >> tt;
  while (tt--) {
    long long l, r;
    cin >> n >> l >> r;
    s.assign(n + 1, 0);
    for (int i = 1; i <= n; i++) {
      s[i] = s[i - 1] + (2 * (n - i));
    }
    for (long long i = l; i <= r; i++) {
      cout << solve(i) << " \n"[i == r];
    }
  }
  return 0;
}
