文件名称:paradise
介绍说明--下载内容均来自于网络,请自行研究使用
编写一个程序求解迷宫问题,迷宫是一个m行n列的0-1矩阵,其中0表示无障碍,1表示有障碍,设入口为(1,1),出口为(m,n),每次移动只能从一个无障碍的单元移到其周围8个方向上任一无障碍的单元,编制程序给出一条通过迷宫的路径。
要求:(1)输入m*n的迷宫矩阵,如:
6 9
0 1 0 0 0 1 1 0 0
1 0 0 0 1 1 0 1 1
0 1 1 0 0 0 0 1 1
1 1 0 1 1 1 1 0 1
1 1 0 1 0 0 1 0 0
0 0 1 1 1 0 1 1 0-Write a program to solve the maze, the maze is an m-by-n matrix of 0-1, where 0 is accessible, 1 means there is an obstacle, set entrance (1,1), export (m, n), each Accessible only from a mobile unit moves around eight directions took an accessible unit, the preparation procedures are given a path through the maze. Requirements: (1) Input maze m* n matrix, such as: 6 9 0 1 0 0 0 1 1 0 0 1 0 0 0 1 1,011,011,000,011,110,111 1 0 1,110,100,100,001,110,110
要求:(1)输入m*n的迷宫矩阵,如:
6 9
0 1 0 0 0 1 1 0 0
1 0 0 0 1 1 0 1 1
0 1 1 0 0 0 0 1 1
1 1 0 1 1 1 1 0 1
1 1 0 1 0 0 1 0 0
0 0 1 1 1 0 1 1 0-Write a program to solve the maze, the maze is an m-by-n matrix of 0-1, where 0 is accessible, 1 means there is an obstacle, set entrance (1,1), export (m, n), each Accessible only from a mobile unit moves around eight directions took an accessible unit, the preparation procedures are given a path through the maze. Requirements: (1) Input maze m* n matrix, such as: 6 9 0 1 0 0 0 1 1 0 0 1 0 0 0 1 1,011,011,000,011,110,111 1 0 1,110,100,100,001,110,110
(系统自动生成,下载前可以参看下载内容)
下载文件列表
新建 文本文档.txt