Problem: The king is left alone on the chessboard. In spite of this loneliness, he doesn't lose heart, because he has business of national importance. For example, he has to pay an official visit to square t. As the king is not in habit of wasting his time, he wants to get from his current position s to square t in the least number of moves. Help him to do this.

<image>

In one move the king can get to the square that has a common side or a common vertex with the square the king is currently in (generally there are 8 different squares he can move to).

Input

The first line contains the chessboard coordinates of square s, the second line — of square t.

Chessboard coordinates consist of two characters, the first one is a lowercase Latin letter (from a to h), the second one is a digit from 1 to 8.

Output

In the first line print n — minimum number of the king's moves. Then in n lines print the moves themselves. Each move is described with one of the 8: L, R, U, D, LU, LD, RU or RD. 

L, R, U, D stand respectively for moves left, right, up and down (according to the picture), and 2-letter combinations stand for diagonal moves. If the answer is not unique, print any of them. 

Examples

Input

a8
h1


Output

7
RD
RD
RD
RD
RD
RD
RD

Solution (in JAVA):

Solution:
import java.util.*;


import java.io.*;

public class Codeforces 
{
	final static char white=0;
	final static char gray=1;
	final static char black=2;
	 static class FastReader
	    {
	        BufferedReader br;
	        StringTokenizer st;
	 
	        public FastReader()
	        {
	            br = new BufferedReader(new
	                     InputStreamReader(System.in));
	        }
	 
	        String next()
	        {
	            while (st == null || !st.hasMoreElements())
	            {
	                try
	                {
	                    st = new StringTokenizer(br.readLine());
	                }
	                catch (IOException  e)
	                {
	                    e.printStackTrace();
	                }
	            }
	            return st.nextToken();
	        }
	 
	        int nextInt()
	        {
	            return Integer.parseInt(next());
	        }
	 
	        long nextLong()
	        {
	            return Long.parseLong(next());
	        }
	 
	        double nextDouble()
	        {
	            return Double.parseDouble(next());
	        }
	 
	        String nextLine()
	        {
	            String str = "";
	            try
	            {
	                str = br.readLine();
	            }
	            catch (IOException e)
	            {
	                e.printStackTrace();
	            }
	            return str;
	        }
	    }
	 static class Queue
		{
			private	ArrayList<Integer> q;
			
			
			Queue() //default ctor
			{
				q=new ArrayList<Integer>();
			}
			
			Queue(int n) //parameterised ctor
			{
				q=new ArrayList<Integer>(n);
			}
			
			void queue(int o)
			{
				q.add(o);
			}
			
			int dequeue()
			{
				if(q.size()==0)
					return -1;
				else
				{
					 int o=q.get(0);
					 q.remove(0);
					 return o;
				}
			}	
			
			boolean isEmpty()
			{
				if(q.size()==0)
					return true;
				else
					return false;
				
			}
			
		}
	 static class Graph
	 {
		 char[] color;
		 int[] dist; //distance array
		 int[] pred; //predecessor array 
		 int n; 
		 
		 Map<Integer,LinkedList<Integer>> al;
		 Graph(int n) //number of vertices in graph
		 {
			 al=new HashMap<Integer,LinkedList<Integer>>(n);
			 for(int i=1;i<=n;i++)
				 al.put(i, new LinkedList<Integer>());
			 this.n=n;
			 dist=new int[n+1];
			 color=new char[n+1];
			 pred=new int[n+1];
		 }
		 void addEdge(int a,int b)
		 {
			 al.get(a).add(b);
		 }
		 
		 int[] BFS(int v) //v=source vertex for bfs
		 {
			 Arrays.fill(color, white);
			 Arrays.fill(dist, Integer.MAX_VALUE);
			 Arrays.fill(pred, -1);
			 Queue q=new Queue(n);
			
			 dist[v]=0;
			 //System.out.println(dist[v]+" "+v); 
			 color[v]=gray;
			 q.queue(v);
			 while(!q.isEmpty())
			 {
				 int disc=q.dequeue();
				// System.out.println(disc+" disc");
				 color[disc]=black;
				 Iterator<Integer> i=al.get(disc).iterator();
				 while(i.hasNext())
				 {
					 int temp=i.next();
					// System.out.println(temp+" hk");
					 if(color[temp]==white)
					 {
						//System.out.println(temp+" yo");
						 color[temp]=gray;
						 pred[temp]=disc;
						 dist[temp]=dist[disc]+1;
						 
						 q.queue(temp);
					 }
				 }
			 }
			 return dist;
		 }
		 
		 
	 }

	 static int getNo(int i,int j)
	 {
		 return 8*j+i+1;
	 }
	 static String getMove(int pred,int dest)
	 {
		 int d=dest-pred;
		 switch(d)
		 {
		 	case 1: return "R";
		 	case -1: return "L";
		 	case 8: return "U";
		 	case -8: return "D";
		 	case 9: return "RU";
		 	case 7: return "LU";
		 	case -9: return "LD";
		 	case -7: return "RD";
		 }
		 return "";
	 }
	 public static void main(String[] args)
		{
		
		 	FastReader hk=new FastReader();
		 	Graph g=new Graph(64);
		 	for(int i=0;i<8;i++)
		 		for(int j=0;j<8;j++)
		 		{
		 			if(i-1>=0)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i-1,j));
		 			}
		 			if(i-1>=0 && j-1>=0)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i-1,j-1));
		 			}
		 			if(i-1>=0 && j+1<8)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i-1,j+1));
		 			}
		 			if(i+1<8)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i+1,j));
		 			}
		 			if(i+1<8 && j-1>=0)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i+1,j-1));
		 			}
		 			if(i+1<8 && j+1<8)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i+1,j+1));
		 			}
		 			if(j-1>=0)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i,j-1));
		 			}
		 			if(j+1<8)
		 			{
		 				g.addEdge(getNo(i,j), getNo(i,j+1));
		 			}
		 		}
		 	String s1=hk.next();
		 	String s2=hk.next();
		 	int a=getNo(s1.charAt(0)-'a',s1.charAt(1)-'1');
		 	int b=getNo(s2.charAt(0)-'a',s2.charAt(1)-'1');
		 	int[] dist=g.BFS(a);
		 	System.out.println(dist[b]);
		 	Stack<String> s=new Stack<String>();
		 	while(g.pred[b]!=-1)
		 	{
		 		s.push(getMove(g.pred[b],b));
		 		b=g.pred[b];
		 	}
		 	while(!s.isEmpty())
		 		System.out.println(s.pop());
		 /*	for(int i=1;i<=64;i++)
		 	{
		 		LinkedList<Integer> ll=g.al.get(i);
		 		Iterator<Integer> j=ll.iterator();
		 		System.out.print("list of "+i+": " );
		 		while(j.hasNext())
		 		{
		 			
		 			System.out.print(j.next()+" ");
		 		}
		 		System.out.println();
		 			
		 	}*/
		 /*	for(int i=1;i<=64;i++)
		 		System.out.println("pred "+i+" "+g.pred[i]);*/
		}	

}