#P1271. 【深基9.例1】选举学生会
【深基9.例1】选举学生会
Description
The school is electing student union members. There are () candidates, and each candidate is numbered from to . Now () ballots have been collected, and each ballot has a candidate number written on it. Now we want to sort this mountain of ballots in ascending order by the vote number. Let the number on the -th () ballot be , and it is guaranteed that .
Input Format
Input and , followed by the numbers on the ballots.
Output Format
Output the ballot numbers after sorting.
5 10
2 5 2 2 5 2 2 2 1 2
1 2 2 2 2 2 2 2 5 5
Hint
Translated by ChatGPT 5
京公网安备 11011102002149号