#000602

Kuglice

You are given n bowls of beads. You can take a bead from one bowl and move it to some other bowl. Find the smallest number k, such that no bowl contains more than k beads after at most m beads are moved.



InputThe first line of standard input contains two integers n and m (1 <= n <= 100.000, 1 <= m <= 1.000.000.000), number of bowls and maximum number of moves.
In the second line there are n integers from the interval [0, 1.000.000.000] that represent the number of beads in each of the n bowls.


OutputIn the first and the only line of standard output print the number k.



Input:
5 7
11 3 8 3 4


Output:
6

Submit solution

Coming later

The grading service will be connected in a later migration step. You can inspect the task and your previous results now.