I would like to know how to use the Manhattan Distance heureustic to drive my search in NxN 2d array. i have the following manhattan distance :
private int manhattan(int[] pos, ...
I'm implementing NxN puzzels in java 2D array int[][] state. am required to use the manhattan heureustic in the following way:
...
I would like to know the difference in calculating the manhattan distance of the following code snipets. I have 2D array int[][] state and want to calculate the manahattan distance ...
int[][] state