CF1328F 题解

CF1328F 题解

$\text{Descrption}$

给定 $n$ 个数,每次可以将最小的数加一或者将最大的数减一,问要有 $k$ 个相等的数最少需要多少此操作。

$n,k\le 2\times 10^5,a_i\le 10^9$。

Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×