【例58.2】 序列处理
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
Description
Given a sequence of integers, output their sum, maximum value, minimum value, and the sequence sorted in descending order (with duplicates removed).
Input Format
The first line contains an integer ().
The second line contains integers ().
Output Format
The first line outputs an integer representing the sum.
The second line outputs an integer representing the maximum value.
The third line outputs an integer representing the minimum value.
The fourth line outputs a sequence of integers separated by spaces, representing the sequence sorted in descending order (with duplicates removed).
Sample
8
8 5 1 9 2 6 2 639
9
1
9 8 6 5 2 1
20251018C班作业(3)
- Status
- Done
- Problem
- 5
- Open Since
- 2025-10-23 0:00
- Deadline
- 2025-10-30 23:59
- Extension
- 24 hour(s)