文件名称:Find
-
所属分类:
- 标签属性:
- 上传时间:2012-11-16
-
文件大小:1.13kb
-
已下载:0次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
北邮复试上机题(两种方法):
Descr iption
在平面上的n个点中找出横坐标最小的点。
Input
第一行是一个正整数n(1<=n<=1000),表示一共有n个点。
接下来n行,每行2个整数,分别表示每个点的横坐标和纵坐标。
Output
输出横坐标最小的那个点的横坐标和纵坐标,如果横坐标最小的点有多个,则只输出其中纵坐标最小的那个点。
Sample Input
5
5 2
2 3
2 4
3 2
4 1
Sample Output
2 3-Descr iption
N points on the plane to find the abscissa of the minimum point.
Input
The first line is a positive integer n (1 <= n <= 1000), said a total of n points.
The next n lines, each line two integers that represent horizontal and vertical coordinates of each point.
Output
Output abscissa of the minimum point of abscissa and ordinate, if the abscissa of the minimum point, only the output of which the vertical axis the smallest point.
Sample Input
5
52
23
24
32
41
Sample Output
23
Descr iption
在平面上的n个点中找出横坐标最小的点。
Input
第一行是一个正整数n(1<=n<=1000),表示一共有n个点。
接下来n行,每行2个整数,分别表示每个点的横坐标和纵坐标。
Output
输出横坐标最小的那个点的横坐标和纵坐标,如果横坐标最小的点有多个,则只输出其中纵坐标最小的那个点。
Sample Input
5
5 2
2 3
2 4
3 2
4 1
Sample Output
2 3-Descr iption
N points on the plane to find the abscissa of the minimum point.
Input
The first line is a positive integer n (1 <= n <= 1000), said a total of n points.
The next n lines, each line two integers that represent horizontal and vertical coordinates of each point.
Output
Output abscissa of the minimum point of abscissa and ordinate, if the abscissa of the minimum point, only the output of which the vertical axis the smallest point.
Sample Input
5
52
23
24
32
41
Sample Output
23
(系统自动生成,下载前可以参看下载内容)
下载文件列表
Find.cpp
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.