hourse

所属分类:界面编程
开发工具:Visual C++
文件大小:46KB
下载次数:15
上传日期:2006-04-11 12:05:11
上 传 者在奋斗也在生活
说明:  算法的基本思路是: 定义结构体: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 (3139, 2003-12-28)
跳马\Knight.exe (204860, 2003-12-28)
跳马\文档.doc (35328, 2003-12-28)
跳马 (0, 2006-02-20)

近期下载者

相关文件


收藏者