#CCBCHBA0000033. Highest and Position (Highest and Position)
Highest and Position (Highest and Position)
Highest and Position
Source: beecrowd
Version: Phuoc Hung OJ Extended
Problem Statement
Read exactly 100 integers and output the maximum value and its first 1-based position on separate lines.
Input
Exactly 100 positive integers in [1,100000] (PHOJ Extended bound); no leading n.
Output
Line 1: maximum value; line 2: first 1-based position.
Subtasks
- Subtask 1 (20%): 100 số, mỗi số .
- Subtask 2 (30%): 100 số, mỗi số .
- Subtask 3 (50%): 100 số, mỗi số .
Examples
Example 1
Input
9
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
Output
9
1
Explanation
First value is 9, all remaining 99 are 1; output 9 and position 1.