P8717 [Lanqiao Cup 2020 NOI Qualifier AB2] Score Analysis

Description

Xiao Lan organized an exam for the students. The full score of the paper is $100$ points, and each student's score is an integer from $0$ to $100$. Please compute the highest score, the lowest score, and the average score for this exam.

Input Format

The first line of input contains an integer $n$, which indicates the number of students taking the exam. The next $n$ lines each contain an integer from $0$ to $100$, representing a student's score.

Output Format

Output three lines. The first line contains an integer, representing the highest score. The second line contains an integer, representing the lowest score. The third line contains a real number, rounded to exactly two decimal places, representing the average score.

Explanation/Hint

For $50\%$ of the testdata, $1 \leq n \leq 100$. For all testdata, $1 \leq n \leq 10000$. Lanqiao Cup 2020 Round 2 Provincial Contest, Group A Problem F (Group B Problem F). Translated by ChatGPT 5