n, m = gets.chomp.split.map(&:to_i)
arr = gets.chomp.split.map(&:to_i)
max = [arr[0] - 1, n - arr[-1]].max
prev = arr[0]
arr[1..-1].each{|x|
    max = (x - prev) / 2 if max < (x - prev) / 2
    prev = x
}
puts max
