登录
首页 » C# » “小鼠迷宫问题;问题描述:一只活老鼠B M 1。鼠标

“小鼠迷宫问题;问题描述:一只活老鼠B M 1。鼠标

于 2022-03-21 发布 文件大小:1.64 kB
0 92
下载积分: 2 下载次数: 1

代码说明:

小鼠迷宫问题« 问题描述:小鼠a 与小鼠b身处一个m×m的迷宫中,如图所示。每一个方格表示迷宫中的一个房间。这m×n个房间中有一些房间是封闭的,不允许任何人进入。在迷宫中任何位置均可沿上,下,左,右4个方向进入未封闭的房间。小鼠a位于迷宫的(p,q)方格中,它必须找出一条通向小鼠b 所在的(r,s)方格的路。请帮助小鼠a找出一条通向小鼠b的道路。« 编程任务:对于给定的小鼠的迷宫,编程计算小鼠a 通向小鼠b的道路。« 数据输入:由文件input.txt 给出输入数据。第一行有2 个正整数m,k,分别表示迷宫的行数和封闭的房间数。接下来的k行中,每行2 个正整数,表示被封闭的房间所在的行号和列号。最后的2 行,每行也有2 个正整数,分别表示小鼠a 所处的方格(p,q)和小鼠b 所处的方格(r,s)。« 结果输出:将计算出的小鼠a 通向小鼠b 的道路输出到文件output.txt。输出文件的每行2 个正整数,表示道路行号和列号,从终点向起点方向列出。如果小鼠a 无法通向小鼠b 则输出“No Solution!”-mice problem laquo maze; Problem description : mouse with a live mouse b m 1 m maze of dummies. Each expressed a box maze of a room. This m n rooms there were some rooms are closed, did not allow anyone to enter. The maze can be any location along the upper and lower, right and left four entered no closed rooms. Mice in a maze of (p, q) box, it must find a leading mice where the b (r, s) box at the road. Please help find a mouse a mouse b leading to the road. Laquo; Programming tasks : to the mice in a maze

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • BMS方案设计
    说明:  BMS的软硬件设计方案,内含1. GUI软件安装文件;2. 原理图及PCB文件;3. 完整用户手册(Software and hardware design of BMS)
    2020-06-23 11:44:37下载
    积分:1
  • 液晶 4 位 8051
    液晶屏 4 位模式 8051 接口到写在 C MCS-51
    2023-04-22 14:00:02下载
    积分:1
  • RC522
    实现RC522射频芯片的读写,扣费,注册,和充值等功能,51单片机绝得可以用(RC522 RF chip to read and write, chargeback, registration, and recharge function, 51 MCU must have to be able to use)
    2021-04-25 02:28:47下载
    积分:1
  • wavelet_.M
    一维信号的小波去噪,这是一个很好的基于小波变换的小波去噪,是针对一维的,去噪效果非常好!(1DWT wavelet denoide)
    2015-09-22 19:57:53下载
    积分:1
  • windoiwISAM
    求解TSP问题的遗传算法matlab程序(Genetic algorithm matlab Program for solving TSP problem)
    2018-09-05 12:57:33下载
    积分:1
  • parallel_alg_source_code
    高教出版社的《并行算法实践》一书的源代码,内容为MPI程序源代码(Higher Education Publishing House s Parallel Algorithm for the practice of the book s source code, content for the MPI source code)
    2007-12-13 13:53:32下载
    积分:1
  • qt+vs2010 3D图形的建立
    vs建立Qt的opengl工程,绘制3维图形,导入纹理图片  注释部分为平面图形
    2022-05-05 09:28:19下载
    积分:1
  • MX90640_STM32_HAL移植
    说明:  测温矩阵传感器MLX90640的stm32移植版本,基于HAL库的硬件IIC驱动文件。(The STM32 porting version of mlx90640 is based on the hardware IIC driver file of Hal library.)
    2021-01-11 09:48:49下载
    积分:1
  • rqueue-aodv
    说明:  多播协议源代码分析,此代码是在AODV协议上的改进算法。(Multicast protocol source code analysis, this code is in the improved algorithm of AODV protocol.)
    2011-04-14 19:15:21下载
    积分:1
  • Trend Arrows
    A great indicator for binary options that works upon market trends.
    2020-06-18 09:20:02下载
    积分:1
  • 696516资源总数
  • 106442会员总数
  • 11今日下载