文件名称:ProgramA
-
所属分类:
- 标签属性:
- 上传时间:2014-03-11
-
文件大小:749byte
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
skiing
时间限制:3000 ms | 内存限制:65535 KB
难度:5
描述
Michael喜欢滑雪百这并不奇怪, 因为滑雪的确很刺激。可是为了获得速度,滑的区域必须向下倾斜,而且当你滑到坡底,你不得不再次走上坡或者等待升降机来载你。Michael想知道载一个区域中最长底滑坡。区域由一个二维数组给出。数组的每个数字代表点的高度。下面是一个例子
1 2 3 4 5
16 17 18 19 6
15 24 25 20 7
14 23 22 21 8
13 12 11 10 9
一个人可以从某个点滑向上下左右相邻四个点之一,当且仅当高度减小。在上面的例子中,一条可滑行的滑坡为24-17-16-1。当然25-24-23-...-3-2-1更长。事实上,这是最长的一条。
输入
第一行表示有几组测试数据,输入的第二行表示区域的行数R和列数C(1 <= R,C <= 100)。下面是R行,每行有C个整数,代表高度h,0<=h<=10000。
后面是下一组数据;
输出
输出最长区域的长度。
样例输入
1
5 5
1 2 3 4 5
16 17 18 19 6
15 24 25 20 7
14 23 22 21 8
13 12 11 10 9
样例输出
25-skiing
Time Limit : 3000 ms | Memory Limit : 65535 KB
Difficulty: 5
Descr iption
Michael likes to ski one hundred This is not surprising , because skiing is very exciting. However, in order to gain speed , the area must be downward slide , and when you slide into the base , you have to lift up the grade again or wait for you to upload . Michael wanted to know an area set up at the end landslide . Given by a two-dimensional area array . Each number represents the height of the point of the array . Here is an example
12345
161718196
152425207
142322218
131211109
A person can slide up and down from a point adjacent to one of the four points , and only when the height is reduced. In the above example , one can slide the sliding 24-17-16-1 . Of course 25-24-23- ...-3-2-1 longer. In fact, this is the longest one .
Enter
The first line indicates that there are several sets of test data, the second line of the input area , said the number of rows and columns R C (1 <=
时间限制:3000 ms | 内存限制:65535 KB
难度:5
描述
Michael喜欢滑雪百这并不奇怪, 因为滑雪的确很刺激。可是为了获得速度,滑的区域必须向下倾斜,而且当你滑到坡底,你不得不再次走上坡或者等待升降机来载你。Michael想知道载一个区域中最长底滑坡。区域由一个二维数组给出。数组的每个数字代表点的高度。下面是一个例子
1 2 3 4 5
16 17 18 19 6
15 24 25 20 7
14 23 22 21 8
13 12 11 10 9
一个人可以从某个点滑向上下左右相邻四个点之一,当且仅当高度减小。在上面的例子中,一条可滑行的滑坡为24-17-16-1。当然25-24-23-...-3-2-1更长。事实上,这是最长的一条。
输入
第一行表示有几组测试数据,输入的第二行表示区域的行数R和列数C(1 <= R,C <= 100)。下面是R行,每行有C个整数,代表高度h,0<=h<=10000。
后面是下一组数据;
输出
输出最长区域的长度。
样例输入
1
5 5
1 2 3 4 5
16 17 18 19 6
15 24 25 20 7
14 23 22 21 8
13 12 11 10 9
样例输出
25-skiing
Time Limit : 3000 ms | Memory Limit : 65535 KB
Difficulty: 5
Descr iption
Michael likes to ski one hundred This is not surprising , because skiing is very exciting. However, in order to gain speed , the area must be downward slide , and when you slide into the base , you have to lift up the grade again or wait for you to upload . Michael wanted to know an area set up at the end landslide . Given by a two-dimensional area array . Each number represents the height of the point of the array . Here is an example
12345
161718196
152425207
142322218
131211109
A person can slide up and down from a point adjacent to one of the four points , and only when the height is reduced. In the above example , one can slide the sliding 24-17-16-1 . Of course 25-24-23- ...-3-2-1 longer. In fact, this is the longest one .
Enter
The first line indicates that there are several sets of test data, the second line of the input area , said the number of rows and columns R C (1 <=
(系统自动生成,下载前可以参看下载内容)
下载文件列表
ProgramA.cpp
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.