n = gets.to_i
arr = gets.chomp.split.map(&:to_i)

100.downto(1){|d|
    flag = false
    work = 0
    arr.each{|x|
        work += x
        work -= d
        if work < 0
            flag = true
            break
        end
    }
    if !flag
        puts d
        break
    end
}
