from sys import stdin
import numpy as np
from numba import njit, i8
n, k = map(int, stdin.readline().split())
a = np.array(stdin.readline().split(), dtype = np.int64)

@njit(cache=True)
def c(x, a):
    res = 0
    for i in range(n):
        res += 0 - - a[i] // x - 1
    return res <= k

ng = 0
ok = 10 ** 9 + 1
while ok - ng > 1:
    mid = (ok + ng) >> 1
    if c(mid, a):
        ok = mid
    else:
        ng = mid
print(ok) from sys import stdin import numpy as np numpy from numba import njit, i8 n, k = map(int, stdin.readline().split()) n map(int, stdin.readline().split()) map int stdin.readline().split() stdin.readline().split stdin.readline() stdin.readline stdin readline split k a = np.array(stdin.readline().split(), dtype = np.int64) a np.array(stdin.readline().split(), dtype = np.int64) np.array np array stdin.readline().split() stdin.readline().split stdin.readline() stdin.readline stdin readline split dtype = np.int64 dtype np.int64 np int64 def c(x, a):
    res = 0
    for i in range(n):
        res += 0 - - a[i] // x - 1
    return res <= k c res = 0 res 0 for i in range(n):
        res += 0 - - a[i] // x - 1
     i range(n) range n res += 0 - - a[i] // x - 1 res 0 - - a[i] // x - 1 0 - - a[i] // x 0 - a[i] // x - a[i] a[i] a i x 1 return res <= k res <= k res k x x a a @njit(cache=True) c cache=True @njit(cache=True) njit cache=True cache True c ng = 0 ng 0 ok = 10 ** 9 + 1 ok 10 ** 9 + 1 10 ** 9 10 9 1 while ok - ng > 1:
    mid = (ok + ng) >> 1
    if c(mid, a):
        ok = mid
    else:
        ng = mid ok - ng > 1 ok - ng ok ng 1 mid = (ok + ng) >> 1 mid (ok + ng) >> 1 ok + ng ok ng 1 if c(mid, a):
        ok = mid
    else:
        ng = mid c(mid, a) c mid a ok = mid ok mid ng = mid ng mid print(ok) print ok def c(x, a):
    res = 0
    for i in range(n):
        res += 0 - - a[i] // x - 1
    return res <= k def c(x, a):
    res = 0
    for i in range(n):
        res += 0 - - a[i] // x - 1
    return res <= k c ok = 10 ** 9 + 1 10 ** 9 + 1 ok mid = (ok + ng) >> 1 (ok + ng) >> 1 mid n, k = map(int, stdin.readline().split()) map(int, stdin.readline().split()) n ng = 0 0 ng k = map(int, stdin.readline().split()) map(int, stdin.readline().split()) k a = np.array(stdin.readline().split(), dtype = np.int64) np.array(stdin.readline().split(), dtype = np.int64) a ok = mid mid ok ng = mid mid ng
from sys import stdin
import numpy as np
from numba import njit, i8
n, k = map(int, stdin.readline().split())
a = np.array(stdin.readline().split(), dtype = np.int64)

@njit(cache=True)
def c(x, a):
    res = 0
    for i in range(n):
        res += 0 - - a[i] // x - 1
    return res <= k

ng = 0
ok = 10 ** 9 + 1
while ok - ng > 1:
    mid = (ok + ng) >> 1
    if c(mid, a):
        ok = mid
    else:
        ng = mid
print(ok)
