import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.io.PrintWriter; class Main { static PrintWriter out = new PrintWriter(System.out); public static void main(String[] args) throws IOException { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); int num = Integer.parseInt(br.readLine()); int point; for (int i = 0; i < num; i++) { point = Integer.parseInt(br.readLine()); len(point); out.println(); } br.close(); out.flush(); } public static int len(int point) { if (point == 0) { return 0; } else { if (point % 2 == 0) { out.print("R"); return len((point - 1) / 2); } else { out.print("L"); return len(point / 2); } } } }