文件名称:hourse
介绍说明--下载内容来自于网络,使用问题请自行百度
算法的基本思路是:
定义结构体:struct PLACE{int x, int y}表示棋盘上的位置。
依题意,马每跳一步之后都可以从七个不同的方向选择下一步的跳马,当然,前提是跳的这一步在棋盘内且它前面的任何一步都没跳到这一格子上(限界),就可以认为这一步跳成功,否则跳马不成功。若跳马不成功,则找下一个方向尝试跳马,若七个方向都跳马不成功,则回溯。
-algorithm for the basic ideas : the structure definition : PLACE struct (int x, int y) expressed position on the chessboard. According to that intended, Ma every step dancing followed from 7 to choose a different direction next vault, of course, the premise is this step jump on the chessboard in front of it, within any step no jumping on the lattice (Bound), that could jump to success, or else vault unsuccessful. Vault if unsuccessful, to find a direction to vault, if the seven directions vault unsuccessful, then backtracking.
定义结构体:struct PLACE{int x, int y}表示棋盘上的位置。
依题意,马每跳一步之后都可以从七个不同的方向选择下一步的跳马,当然,前提是跳的这一步在棋盘内且它前面的任何一步都没跳到这一格子上(限界),就可以认为这一步跳成功,否则跳马不成功。若跳马不成功,则找下一个方向尝试跳马,若七个方向都跳马不成功,则回溯。
-algorithm for the basic ideas : the structure definition : PLACE struct (int x, int y) expressed position on the chessboard. According to that intended, Ma every step dancing followed from 7 to choose a different direction next vault, of course, the premise is this step jump on the chessboard in front of it, within any step no jumping on the lattice (Bound), that could jump to success, or else vault unsuccessful. Vault if unsuccessful, to find a direction to vault, if the seven directions vault unsuccessful, then backtracking.
(系统自动生成,下载前可以参看下载内容)
下载文件列表
跳马/Knight.cpp
跳马/Knight.exe
跳马/文档.doc
跳马
www.dssz.com.txt
跳马/Knight.exe
跳马/文档.doc
跳马
www.dssz.com.txt
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.