Maximum Value
Time limit1sMemory limit128 MB
Read nine distinct natural numbers and print the maximum value along with its 1-based position.
- Level
Easy1 of 10
- Topics
- Array, Implementation
- Solved
- No attempts yet
Problem
Given nine distinct natural numbers, find the largest value and the 1-based position at which it appears in the input.
Input
Nine lines are given. Each line contains one natural number. All numbers are distinct and less than 100.
Output
Print the maximum value on the first line. Print its 1-based position in the input on the second line.