文件名称:horse1
介绍说明--下载内容均来自于网络,请自行研究使用
首先从起始点开始看它的八个方向中有几个方向可以走,假如有5个方向可走,再看这5个位置下一步分别有几步可走,把这个值赋给一个数组s[],再对数组进行从小到大排序,然后从5步中s[]值最小的走,依次递归,每次从s[]值最小的走,如果步骤号step等于棋盘规格m*n,则说明全部走完了;如果遇到无路可走的情况,step--,退回到上一步,当一直退到起始点时候,说明无法全部遍历。-First of all, look at it from the starting point for the beginning of the eight directions in a few directions to go, if the direction has to take five, look at this 5 position, respectively, the next step may have a few steps away, and this value assigned to an array s [], and then carried out on the array from small to large order, and then from step 5 s [] value of the smallest go, followed by recursive, each from the s [] the value of taking the smallest, if steps step No. chessboard specifications equivalent to m* n , then the full journey if the situation encountered nowhere to go, step, back to the previous step, when time has been moved back to the starting point that can not be all ergodic.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
新建文件夹
..........\madebianliwenti.doc
..........\madebianliwenti.doc