#4442. Find Takahashi

0
    ID: 4442 传统题 2000ms 1024MiB 尝试: 3 已通过: 2 难度: 1 上传者: 标签>AtCoderabc275AGESP 1级枚举(单层循环)

Find Takahashi

Find Takahashi

题目描述

There are NN bridges in AtCoder Village. The height of the bridge numbered ii is HiH_i (ii is an integer between 11 and NN).
村里每座桥都有不同的高度。打印代表最高桥编号的整数。 Print the number representing the highest bridge in the village.

输入格式

The input is given from Standard Input in the following format: NN H1H_1 H2H_2 …\ldots HNH_N

输出格式

Print the integer representing the highest bridge in AtCoder village.

3
50 80 70
2
1
1000000000
1
10
22 75 26 45 72 81 47 29 97 2
9

提示

1≤N≤1001\leq N \leq 100 1≤Hi≤1091\leq H_i \leq 10^9 All HiH_i are different. All values in the input are integers.The village has three bridges.
该村有三座桥。
The first, second, and third bridges have heights of 5050, 8080, and 7070, respectively, 第一座、第二座和第三座桥的高度分别是 5050、8080 和 7070, so the second bridge is the highest.
因此第二座桥是最高的。
Thus, 22 should be printed.
The village has only one bridge, so the first bridge is the highest.
The village has ten bridges, and the ninth bridge (with a height of 9797) is the highest.
因此应该输出 22。
该村只有一座桥,所以第一座桥是最高的。
该村有十座桥,第九座桥(高度为 9797)是最高的。

标签: AtCoder|abc275A

来源

AtCoder|abc275A