- 6
- 0
- 约4.8千字
- 约 5页
- 2016-12-23 发布于重庆
- 举报
#includestdio.h
#includemalloc.h
#includestdlib.h
#includetime.h
#includemath.h
//函数状态码定义
#define TRUE 1
#define FALSE 0
#define OK 1
#define ERROR 0
#define INFEASIBLE -1
#define NULL 0
//墙或通路及前进方向符号定义
#define WALL 0 //代表当前格子是墙
#define PATH 1 //代表是通路且未走过
#define RIGHT -1 //代表是通路且从其向右走
#define DOWN -2 //代表是通路且从其向下走
#define LEFT -3 //代表是通路且从其向左走
#define UP -4 //代表是通路且从其向上走
#define BACK -5 //代表是通路且从其后退一步
#define DESTINATION -6 //代表当前格子是通路且是目标位置
typedef int MazeType[10][10]; //最外凿初始化成墙,实际含*8个格子
原创力文档

文档评论(0)