#C8871. Maximum People Recorded by Sensors
Maximum People Recorded by Sensors
Maximum People Recorded by Sensors
In this problem, you are given data from multiple sensors, each providing a sequence of readings that indicate the number of people recorded over consecutive time intervals. Your task is to determine the maximum number of people recorded by each sensor.
Formally, for each sensor, you are given an integer (N) and a sequence of (N) readings (a_1, a_2, \dots, a_N). You need to output the maximum value among these readings.
Note: The input is read from standard input and the output is written to standard output.
inputFormat
The first line contains an integer (T) denoting the number of sensors. For each sensor, the first line contains an integer (N) representing the number of readings, followed by a line containing (N) space-separated integers, which are the sensor readings.
outputFormat
For each sensor, output a single line containing the maximum reading recorded by that sensor.## sample
3
5
1 2 3 2 1
3
10 20 10
4
15 25 35 30
3
20
35
</p>