#P189. 练31.1 年龄与疾病
练31.1 年龄与疾病
Description
A hospital wants to analyze whether the occurrence of a certain disease is related to age. They need to organize past diagnostic records and calculate the proportion of patients in each of the following age groups: , , , and and above (inclusive), relative to the total number of patients.
Input Format
The input consists of lines. The first line contains the number of past patients (), and the second line contains the age of each patient at the time of diagnosis, with ages being non-negative integers not exceeding .
Output Format
Output the proportion of patients in each of the four age groups (, , , and and above) as a percentage of the total number of patients, rounded to two decimal places. Each age group should be on a separate line, for a total of four lines.
Sample
10
1 11 21 31 41 51 61 71 81 9120.00%
20.00%
20.00%
40.00%