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

v_arr = v_arr.sort
answer = 0
v_arr.each_with_index do |v, index|
  if index == 0 or index == 1
    answer += 1.0 * v / 2 ** (n - 1)
  else
    answer += 1.0 * v / 2 ** (n - index)
  end
end
puts answer
