import sys read = sys.stdin.buffer.read readline = sys.stdin.buffer.readline readlines = sys.stdin.buffer.readlines N,*A = map(int,read().split()) words = [''] * 4095 for n in range(1,4095): words[n] = words[(n-1)//2] + ('L' if n&1 else 'R') print('\n'.join(words[n] for n in A))