文件名称:cut-grass
- 所属分类:
- 数学计算/工程计算
- 资源属性:
- [Windows] [Visual.Net] [源码]
- 上传时间:
- 2013-10-14
- 文件大小:
- 450kb
- 下载次数:
- 0次
- 提 供 者:
- ken***
- 相关连接:
- 无
- 下载说明:
- 别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容均来自于网络,请自行研究使用
有一个n*m的草坪(1<=n,m<=100),草坪中的草原来的高度都是100。现在使用割草机修剪草坪,来得到各种各样的图案。割草机只能横着或者竖着割草。每次割草都会先设定一个高度,割完之后会把比设定高度高的草都割成设定的高度。比如草原来是5 2 8,设定高度为4,那么割完之后就变成了4 2 4。
现在给出一个图案,问是否可以把草坪割成图案的样子。
输入第一行包含两个整数n和m。
接下来为n行输入,每行包含m个不大于100的正整数。
如果可以修剪成输入的图案,则输出“YES”,否则输出“NO”。-There is an n* m lawn (1 <= n, m <= 100), the prairie grass height is 100. Now use mowing the lawn mower to get a variety of patterns. Only horizontally or vertically mower mowing. Each mowing will first set a height higher than the set will then mown grass are cut into high altitude setting height. Such as prairie is 528, set height to 4, after the mown becomes 424.
Now given a pattern, asked if they could put the lawn cut into patterns look.
Input The first line contains two integers n and m.
Next, the n input lines, each containing not more than 100 m a positive integer.
If you can trim an input pattern, the output "YES", otherwise output "NO".
现在给出一个图案,问是否可以把草坪割成图案的样子。
输入第一行包含两个整数n和m。
接下来为n行输入,每行包含m个不大于100的正整数。
如果可以修剪成输入的图案,则输出“YES”,否则输出“NO”。-There is an n* m lawn (1 <= n, m <= 100), the prairie grass height is 100. Now use mowing the lawn mower to get a variety of patterns. Only horizontally or vertically mower mowing. Each mowing will first set a height higher than the set will then mown grass are cut into high altitude setting height. Such as prairie is 528, set height to 4, after the mown becomes 424.
Now given a pattern, asked if they could put the lawn cut into patterns look.
Input The first line contains two integers n and m.
Next, the n input lines, each containing not more than 100 m a positive integer.
If you can trim an input pattern, the output "YES", otherwise output "NO".
(系统自动生成,下载前可以参看下载内容)
下载文件列表
2. 修剪草坪\2. 修剪草坪\2. 修剪草坪.cpp
...........\...........\2. 修剪草坪.vcxproj
...........\...........\2. 修剪草坪.vcxproj.filters
...........\...........\Debug\2. 修剪草坪.obj
...........\...........\.....\............tlog\2. 修剪草坪.lastbuildstate
...........\...........\.....\................\CL.read.1.tlog
...........\...........\.....\................\CL.write.1.tlog
...........\...........\.....\................\link.read.1.tlog
...........\...........\.....\................\link.write.1.tlog
...........\...........\.....\vc120.idb
...........\...........\.....\vc120.pdb
...........\2. 修剪草坪.sdf
...........\2. 修剪草坪.sln
...........\2. 修剪草坪.v12.suo
...........\Debug\2. 修剪草坪.exe
...........\.....\2. 修剪草坪.ilk
...........\.....\2. 修剪草坪.pdb
...........\2. 修剪草坪\Debug\2. 修剪草坪.tlog
...........\...........\Debug
...........\2. 修剪草坪
...........\Debug
2. 修剪草坪