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 moves = 0; String move = ""; int i = i_start, j= j_start; while(i_start >=0 && i_start =0 && j_start 0 && i_start == i && j_start == j) { break; } else if(j_start == j_end && Math.abs(i_start - i_end) == 1){ break; } else if(i_start == i_end && Math.abs(j_start - j_end) == 1){ break; } if(i_start > i_end && j_start >= j_end) { i_start -= 2; j_start -= 1; move +="UL "; } else if(i_start < i_end && j_start <= j_end){ i_start += 2; j_start += 1; move +="LR "; } else if(i_start > i_end && j_start < j_end) { i_start -= 2; j_start += 1; move +="UR "; } else if(i_start < i_end && j_start > j_end) { i_start += 2; j_start -= 1; move +="LL "; } else if(i_start == i_end && j_start > j_end) { j_start -= 2; move +="L "; } else if(i_start == i_end && j_start < j_end) { j_start += 2; move +="R "; } //System.out.println(move + " i=" + i_start + " j=" + j_start); moves++; } if(i_start == i_end && j_start == j_end) { System.out.println(moves); System.out.println(move); } else { System.out.println("Impossible"); } } 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(); } }