import java.io.*;
import java.util.*;

public class Ana {

	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);
		PrintWriter out = new PrintWriter(System.out);
//		Thread.sleep(2000);
		int t = sc.nextInt();
		while (t-- > 0) {
			int n = sc.nextInt();long l=sc.nextLong(); long r=sc.nextLong();
			long i=1, count=2;
			while(i<=l) {
				i+=count;
				count+=2;
			}
			
			i-=count-2;
			count/=2;
//			System.out.println(i+" "+ count);
			StringBuilder sb= new StringBuilder();
			boolean first=true;
			while(i<=r) {
				long j;
				if(first) {
					j=((l-i)/2);
					i+=2*j;
					j++;
					first=false;
				}
				else
					j=1;
				for(;j<count;j++) {
					if(i>=l && i<=r) {
						sb.append(j+" "); i++;
					}
					if(i>=l && i<=r) {
						sb.append(count+" "); i++;
					}
					else
						i++;
				}
				count++;
			}
			out.println(sb);
		}
		out.close();
	}

	static class Scanner {
		StringTokenizer st;
		BufferedReader br;

		public Scanner(InputStream s) {
			br = new BufferedReader(new InputStreamReader(s));
		}

		public String next() throws IOException {
			while (st == null || !st.hasMoreTokens())
				st = new StringTokenizer(br.readLine());
			return st.nextToken();
		}

		public int nextInt() throws IOException {
			return Integer.parseInt(next());
		}

		public long nextLong() throws IOException {
			return Long.parseLong(next());
		}

		public String nextLine() throws IOException {
			return br.readLine();
		}

		public boolean ready() throws IOException {
			return br.ready();
		}
	}
}
