class Solve: def __init__(self): self.N = int(input()) self.L = [int(i) for i in input().split()] self.K = int(input()) self.l, self.r = max([l/self.K for l in self.L]), min(max(self.L)+1, sum(self.L)/self.K+1) def check(self, l): idx, s, k = 0, 0, 0 S = sum(self.L) L = list(filter(lambda s: s >= l, self.L)) while(L and k < self.K): s = L.pop() dk = s // l s -= l * dk k += dk return True if k >= self.K else False def solve(self): while self.r - self.l > 10**-9: m = (self.l + self.r) / 2 if self.check(m): self.l = m else: self.r = m return self.l print(Solve().solve())