def query(l,r,c)
  h = (l + r) / 2
  if c == K
    if (h - T).abs <= E then return 1.0
    else return 0.0
    end
  end
  return 0.0 if T - E > r  || l > T + E
  return 1.0 if T - E <= l && r <= T + E

  if h <= T
    return P * query(l, h, c + 1) + (1 - P) * query(h, r, c + 1)
  else
    return (1 - P) * query(l, h, c + 1) + P * query(h, r, c + 1)
  end
end

K,r,l = gets.split.map(&:to_i)
P,E,T = 3.times.map{ gets.to_f }
puts "%.15f" % query(r.to_f, l, 0)