#a. 谁在正中间
谁在正中间
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.
说明
农夫约翰为了找到最“中间”的奶牛,正在调查他的牛群。一半奶牛的产奶量不多于这只“中间”奶牛,另一半的产奶量不少于这只“中间”奶牛。约翰想知道这只“中间”奶牛的产奶量是多少。
给出一个奇数N表示奶牛总数,以及她们的产奶量Ci,要求找出“中间”产量。1≤N≤10000,1≤Ci≤1000000。
输入格式
第1行一个正整数N。
第2~N+1行,每行一个正整数,表示其中一只奶牛的产奶量。
输出格式
一行一个整数,表示“中间”产量的一个整数。
样例
5
2
4
1
3
5
3
20251012编程挑战精英赛训练
- Status
- Done
- Rule
- ACM/ICPC
- Problem
- 51
- Start at
- 2025-9-24 15:00
- End at
- 2025-11-5 7:00
- Duration
- 1000 hour(s)
- Host
- Partic.
- 58