数鸭子
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.
【题目描述】
石榴园的池塘里有三群鸭子,数量分别为 x、y 和 z。
阿者想知道,鸭子最多的那群比最少的那群多多少只。
【输入格式】
从文件 duck.in 中读入数据。
一行三个整数 x, y, z,表示三群鸭子的数量。
【输出格式】
输出到文件 duck.out 中。
输出一个整数,表示答案。
【样例 1 输入】
12 15 10
【样例 1 输出】
5
样例1解释
最大值为 15,最小值为 10,差为 5
【样例 2 输入】
23 23 20
【样例 2 输出】
3
样例2解释
最大值为 23,最小值为 20,差为 3
【样例 3 输入】
18 18 18
【样例 3 输出】
0
样例3解释
最大值和最小值相等,差为 0
【数据范围】
对于 40% 的数据,
对于 100% 的数据,
HIL2026年4月入门组
- Status
- Done
- Rule
- IOI
- Problem
- 4
- Start at
- 2026-4-30 10:30
- End at
- 2026-5-8 18:30
- Duration
- 200 hour(s)
- Host
- Partic.
- 9