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

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

于 2022-03-21 发布 文件大小:1.64 kB
0 70
下载积分: 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 个回复

  • MyGeoMap
    MFC 空间数据的表达与操作,如简单的鼠标查询,输入查询等等。包含简单的SQL数据库查询功能。(MFC expression of spatial data and operation, such as a simple mouse query, enter a query and so on. Contains a simple SQL database query function.)
    2007-10-06 10:45:14下载
    积分:1
  • Wavelet
    说明:  用C语言实现小波变换,有利于初学者更好的理解小波变换过程(Using C language to achieve wavelet transform, is conducive to a better understanding of beginners wavelet transform the process of)
    2021-01-25 21:48:43下载
    积分:1
  • 61C22(ARM)
    这个是用ARM编写的,控制光电编码器的程序,有左右方向的,还有按下状态的功能!(This is prepared using ARM, control procedures optical encoder, there are about the direction, as well as the functions of the state of press!)
    2008-06-13 17:19:37下载
    积分:1
  • panel
    空间计量经济学中空间面板模型的matlab实现程序(Space panel model of spatial econometrics matlab program)
    2013-04-17 16:17:01下载
    积分:1
  • Samples
    gepci5565收发示例,需要的可以试试,vs2015,c++写的(Ge PCI5565 transceiver example)
    2018-06-28 10:43:07下载
    积分:1
  • 基于N76E003的帕灯程序
    说明:  帕灯代码,基于N76E003开发,支持DMX512(PAR_Light,DMX512,N76E003)
    2021-04-04 16:29:04下载
    积分:1
  • C #发达的地图基本浏览器和属性查询的例子!
    c#开发的一个地图基本浏览和属性查询的例子!-c# developed a map of the basic browser and attribute query examples!
    2023-06-05 17:00:04下载
    积分:1
  • gest
    void swap1(int x, int y) //值传递 void swap2(int *px, int *py) //指针传递 void swap3(int &x, int &y) //引用传递 的使用(void swap1(int x, int y) //值传递 void swap2(int*px, int*py) //指针传递 void swap3(int &x, int &y) //引用传递 的使用)
    2012-04-30 16:41:44下载
    积分:1
  • Erika
    upx解压,演示upx解压的程序源码,仅供参考。(upx unpack,show upx unpack program source code)
    2016-03-25 11:07:12下载
    积分:1
  • UKFSharp-master
    用于ukf计算的c#代码 来源于几天几夜的辛勤劳动(none ha ha ha ha ha ha hah)
    2020-06-16 03:20:01下载
    积分:1
  • 696518资源总数
  • 105559会员总数
  • 1今日下载