#3713. [usaco2005 open]Landscaping 地形改造

[usaco2005 open]Landscaping 地形改造

Description

image

Format

Input

第1行输入整数N和K.之后N行,每行输入一个整数,表示这块地的海拔

Output

如果仅能有K个山顶至少要移走多少土.

Samples

12 1
1
2
3
3
3
2
1
3
2
2
1
2
5