#include<bits/stdc++.h>
using namespace std;

#define rep(i, n) for(int i=0; i<n; i++)

static const double EPS = 1E-10;
template<typename T> T add(T x, T y){ if(abs(x+y) < EPS*(abs(x)+abs(y))) return 0; return x + y; }
template<typename T> inline bool semieq(T x, T y){ return abs(x - y) < EPS; }
template<typename T> inline bool semige(T x, T y){ return y - x < -EPS; }
template<typename T> inline bool semile(T x, T y){ return x - y < -EPS; }

int K;
double R, L;
double P, E, T;

inline double solve(int k, double l, double r)
{
  if(semige(r, T + E) || semile(l, T - E)) return 0.0;
  if(!semile(r, T - E) && !semige(l, T + E)) return 1.0;
  double h = (l + r) / 2.0;
  if(k >= K) return !semige(abs(h - T), E) ? 1.0 : 0.0;
  double ret = 0.0;
  if(h >= T){
    ret += P * solve(k + 1, l, h);
    ret += (1.0 - P) * solve(k + 1, h, r);
  }
  else{
    ret += P * solve(k + 1, h, r);
    ret += (1.0 - P) * solve(k + 1, l, h);
  }
  return ret;
}

int main(int argc, char *argv[])
{
  cin >> K >> R >> L;
  cin >> P >> E >> T;

  printf("%.15f\n", solve(0, L, R));
  
  return 0;
}