import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static void printShortestPath(int n, int i_start, int j_start, int i_end, int j_end) { // Print the distance along with the sequence of moves. int move = 0; String path = ""; while(true){ if(i_start == i_end && j_start == j_end) break; if((i_start > i_end && j_start > j_end) || ((+j_start-j_end)>3 && i_start == i_end)){ //System.out.println(1); path += "UL "; i_start -= 2; j_start -= 1; if(check(i_start, j_start, i_end, j_end)){ path = "Impossible"; break; } }else if(i_start > i_end && j_start < j_end){ //System.out.println(2); path += "UR "; i_start -= 2; j_start += 1; if(check(i_start, j_start, i_end, j_end)){ path = "Impossible"; break; } }else if(i_start == i_end && j_start < j_end){ //System.out.println(3); path += "R "; j_start += 2; if(check(i_start, j_start, i_end, j_end)){ path = "Impossible"; break; } }else if((i_start < i_end && j_start < j_end) || ((-i_start+i_end)>2 && j_start == j_end)){ //System.out.println(4); path += "LR "; //System.out.println("i: " + i_start + " j: " + j_start); j_start += 1; i_start += 2; //System.out.println("i: " + i_start + " j: " + j_start); if(check(i_start, j_start, i_end, j_end)){ path = "Impossible"; break; } }else if(i_start < i_end && j_start > j_end){ //System.out.println(5); path += "LL "; j_start -= 1; i_start += 2; //System.out.println("i: " + i_start + " j: " + j_start); if(check(i_start, j_start, i_end, j_end)){ path = "Impossible"; break; } }else{ //System.out.println(6); path += "L "; j_start -= 2; if(check(i_start, j_start, i_end, j_end)){ path = "Impossible"; break; } } //System.out.println("i: " + i_start + " j: " + j_start); move++; } if(path != "Impossible") System.out.println(move); System.out.println(path); } static boolean check(int i_start, int j_start, int i_end, int j_end){ //System.out.println("i: " + i_start + " j: " + j_start); if((Math.abs(i_start-i_end) <= 1 && Math.abs(j_start-j_end) <= 1) && (Math.abs(i_start-i_end) != 0 && Math.abs(j_start-j_end) != 0)) return true; return false; } public static void main(String[] args) { Scanner in = new Scanner(System.in); int n = in.nextInt(); int i_start = in.nextInt(); int j_start = in.nextInt(); int i_end = in.nextInt(); int j_end = in.nextInt(); printShortestPath(n, i_start, j_start, i_end, j_end); in.close(); } }