#include using namespace std; 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 down = i_end - i_start; int right = j_end - j_start; string s=""; int count=0; if(down%2==0 && (abs(right - down/2))%2==0){ while(down!=0 || right!=0){ if(down<0){ if(right<=0){ down+=2; right+=1; s+="UL "; } else{ down+=2; right-=1; s+="UR "; } } else if(right>=0){ if((right-down/2)>0){ right-=2; s+="R "; } else{ down-=2; right-=1; s+="LR "; } } else{ if(down>0){ down-=2; right+=1; s+="LL "; } else{ right+=2; s+="L "; } } count++; } cout<> n; int i_start; int j_start; int i_end; int j_end; cin >> i_start >> j_start >> i_end >> j_end; printShortestPath(n, i_start, j_start, i_end, j_end); return 0; }