import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static int updatedI; static int updatedJ; static int numberOfMoves; static ArrayList orderOfMoves = new ArrayList (); static boolean impossible = false; static void printShortestPath(int n, int i_start, int j_start, int i_end, int j_end) { updatedI = i_start; updatedJ = j_start; numberOfMoves = 0; while(updatedI!=i_end || updatedJ!=j_end){ if(i_end>updatedI && (i_end-updatedI)%2==0 && j_end>updatedJ){ moveLowerRight(updatedI, updatedJ); } else if(i_end>updatedI && (i_end-updatedI)%2==0 && j_endupdatedJ){ moveUpperRight(updatedI, updatedJ); } else if(i_endupdatedJ){ moveRight(updatedJ); } else if(i_end==updatedI && j_endupdatedI && Math.abs(i_end-updatedI)%2==0 && updatedJupdatedI && Math.abs(i_end-updatedI)%2==0 && updatedJ==n){ moveLowerLeft(updatedI, updatedJ); } else if(i_end