Description: Description and purpose of the experiment
8* 8 grid for a given board, find the board a horse from one location to another location to reach the shortest path length.
Note that horse is to take the "day" shape.
Input
Enter a number of test data.
Only 1 line of each test data, each line has 2 squares pos1, pos2, separated by a space, each grid square, said a board position, the position of column 1 by the said letters ( ah), and that the line of a number (1-8) form, such as "d7" said the line 7 column 4.
Output
Each line in the input box on the two pos1, pos2, output horse to jump from position pos1 pos2 shortest path length required. Such as "a1 ==> a2: 3 moves" that jump from position a1 a2 minimum required number of steps is 3.
Note: The sample shown by the output format of the output, such as "a1 ==> a2: 3 moves" in a space after the colon, and then follow the required minimum number of steps.
Experimental results
Input sample
a1 a2
a1 a3
a1 h8
g2 b8
Sample Ou
To Search:
- [dijkstra] - Description of the problem At present th
- [22] - Loading Problem Description and purpose
File list (Check if you may need any files):
horse\horse.dsw
.....\horse.ncb
.....\horse.plg
.....\horse.dsp
.....\horse.cpp
.....\Debug\vc60.idb
.....\.....\vc60.pdb
.....\.....\horse.pch
.....\.....\horse.exe
.....\.....\horse.pdb
.....\.....\horse.obj
.....\.....\horse.ilk
.....\horse.opt
.....\Debug
horse