#P8830. [传智杯 #3 练习赛] 评委打分
[传智杯 #3 练习赛] 评委打分
Problem Description
Xiao A participates in a variety show. There are judges scoring (scores are integers from 0 to 100), and each judge reveals their score in order.
For show effect, starting from the third judge, every time the -th judge gives a score, immediately calculate the contestant's average score among the first judges' scores after removing one highest score and one lowest score. Take the average of the remaining judges' scores and keep decimal places.
Input Format
The first line contains an integer , indicating the number of judges.
The second line contains integers, indicating the scores given by the judges.
Output Format
Output a total of lines, each line representing the corresponding answer.
6
11 45 14 19 19 81
14.00
16.50
17.33
24.25
Hint
Translated by ChatGPT 5