#!/bin/python3 import sys def printShortestPath(n, i_start, j_start, i_end, j_end): s=[] # Print the distance along with the sequence of moves. if (i_end-i_start)%2!=0: print ('Impossible') return if i_start>=n or j_start>=n or i_end>=n or j_end>=n: print ('Impossible') return i=i_start j=j_start count=0 while i!=i_end or j!=j_end: if i==i_end and (j-j_end)%2==1: print ('Impossible') return if (i_end-i)%4==0 and j==j_end: if i_end>i: i=i+4 s.append('LR ') s.append('LL ') count=count+2 elif i0: j=j-2 s.append('L ') count=count+1 if j - j_end < 0: j=j+2 s.append('R ') count=count+1 if j_end > j and i_end j and i_end>i: i=i+2 j=j+1 s.append('LR ') count=count+1 if j_end < j and i_end i: j=j-1 i=i+2 s.append('LL ') count=count+1 print (count) s=''.join(s) print (s) if __name__ == "__main__": n = int(input().strip()) i_start, j_start, i_end, j_end = input().strip().split(' ') i_start, j_start, i_end, j_end = [int(i_start), int(j_start), int(i_end), int(j_end)] printShortestPath(n, i_start, j_start, i_end, j_end)