
n,k = map(int,input().split())
a = list(map(int,input().split()))

l=0
r=10**9

def check(x):
    now = 0
    for i in range(n):
        now += (a[i] - 1 )// x
    return now <= k

while r-l > 1:
    x = (l+r) //2
    if check(x):
        r = x
    else:
        l = x

print(r)
 n,k = map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split k a = list(map(int,input().split())) a list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split l=0 l 0 r=10**9 r 10**9 10 9 def check(x):
    now = 0
    for i in range(n):
        now += (a[i] - 1 )// x
    return now <= k check now = 0 now 0 for i in range(n):
        now += (a[i] - 1 )// x
     i range(n) range n now += (a[i] - 1 )// x now (a[i] - 1 )// x a[i] - 1 a[i] a i 1 x return now <= k now <= k now k x x while r-l > 1:
    x = (l+r) //2
    if check(x):
        r = x
    else:
        l = x r-l > 1 r-l r l 1 x = (l+r) //2 x (l+r) //2 l+r l r 2 if check(x):
        r = x
    else:
        l = x check(x) check x r = x r x l = x l x print(r) print r r=10**9 10**9 r l = x x l x = (l+r) //2 (l+r) //2 x k = map(int,input().split()) map(int,input().split()) k a = list(map(int,input().split())) list(map(int,input().split())) a n,k = map(int,input().split()) map(int,input().split()) n def check(x):
    now = 0
    for i in range(n):
        now += (a[i] - 1 )// x
    return now <= k def check(x):
    now = 0
    for i in range(n):
        now += (a[i] - 1 )// x
    return now <= k check l=0 0 l r = x x r

n,k = map(int,input().split())
a = list(map(int,input().split()))

l=0
r=10**9

def check(x):
    now = 0
    for i in range(n):
        now += (a[i] - 1 )// x
    return now <= k

while r-l > 1:
    x = (l+r) //2
    if check(x):
        r = x
    else:
        l = x

print(r)

