#include <iostream>
#include <algorithm>
#include <utility>
#include <vector>
#include <string>

template <class T, class U>
inline bool chmin(T& lhs, const U& rhs) {
  if (lhs > rhs) {
    lhs = rhs;
    return true;
  }
  return false;
}

template <class T, class U>
inline bool chmax(T& lhs, const U& rhs) {
  if (lhs < rhs) {
    lhs = rhs;
    return true;
  }
  return false;
}

// [l, r) from l to r
struct frep {
  struct itr {
    int i;
    constexpr itr(int i_): i(i_) { }
    constexpr void operator ++ () { ++i; }
    constexpr int operator * () const { return i; }
    constexpr bool operator != (itr x) const { return i != x.i; }
  };
  const itr l, r;
  constexpr frep(int l_, int r_): l(std::min(l_, r_)), r(r_) {}
  constexpr itr begin() const { return l; }
  constexpr itr end() const { return r; }
};

// [l, r) from r to l
struct brep {
  struct itr {
    int i;
    constexpr itr(int i_): i(i_) { }
    constexpr void operator ++ () { --i; }
    constexpr int operator * () const { return i; }
    constexpr bool operator != (itr x) const { return i != x.i; }
  };
  const itr r, l;
  constexpr brep(int l_, int r_): r(std::max(l_, r_) - 1), l(l_ - 1) {}
  constexpr itr begin() const { return r; }
  constexpr itr end() const { return l; }
};

template <class T>
inline T scan() {
  T res;
  std::cin >> res;
  return res;
}

// #define DEBUG
#ifdef DEBUG
#include <iomanip>

void dbg_impl() {
  std::cerr << '\n';
}

template <class Head, class... Tail>
void dbg_impl(const Head& head, const Tail&... tail) {
  std::cerr << ' ' << head;
  dbg_impl(tail...);
}

struct dbg_setup {
  dbg_setup() {
   std::cerr << std::boolalpha;
   std::cerr << std::fixed << std::setprecision(5);
  }
} debug_setup;

#define debug(...)\
  do {\
    std::cerr << std::setw(5) << __LINE__ << "  | ";\
    std::cerr << "[" << #__VA_ARGS__ << "]:";\
    dbg_impl(__VA_ARGS__);\
  } while (false)

#else
#define debug(...) 0
#endif

template <int MODULUS = 1000000007>
struct modulo_int {
private:
  long long value;
  constexpr void normalize() {
    value %= MODULUS;
    if (value < 0) value += MODULUS;
  }
public:
  constexpr modulo_int(long long value_ = 0): value(value_) { normalize(); }
  constexpr modulo_int operator - () const { return modulo_int(MODULUS - value); }
  constexpr modulo_int operator ~ () const { return power(MODULUS - 2); }
  constexpr long long operator () () const { return value; }
  constexpr modulo_int operator + (const modulo_int& rhs) const { return modulo_int(*this) += rhs; }
  constexpr modulo_int& operator += (const modulo_int& rhs) {
    if ((value += rhs.value) >= MODULUS) value -= MODULUS;
    return (*this);
  }
  constexpr modulo_int operator - (const modulo_int& rhs) const { return modulo_int(*this) -= rhs; }
  constexpr modulo_int& operator -= (const modulo_int& rhs) {
    if ((value += MODULUS - rhs.value) >= MODULUS) value -= MODULUS;
    return (*this);
  }
  constexpr modulo_int operator * (const modulo_int& rhs) const { return modulo_int(*this) *= rhs; }
  constexpr modulo_int& operator *= (const modulo_int& rhs) {
    (value *= rhs.value) %= MODULUS;
    return (*this);
  }
  constexpr modulo_int operator / (const modulo_int& rhs) const { return modulo_int(*this) /= rhs; }
  constexpr modulo_int& operator /= (const modulo_int& rhs) {
    return (*this) *= ~rhs;
  }
  constexpr modulo_int power (unsigned long long pow) const {
    modulo_int result(1), mult(*this);
    while (pow > 0) {
      if (pow & 1) result *= mult;
      mult *= mult;
      pow >>= 1;
    }
    return result;
  }
  friend std::istream& operator >> (std::istream& stream, modulo_int& lhs) {
    stream >> lhs.value;
    lhs.normalize();
    return stream;
  }
  friend std::ostream& operator << (std::ostream& stream, const modulo_int& rhs) {
    return stream << rhs.value;
  }
};

template <class T, class U>
struct disjoint_sparse_table {
private:

  std::vector<std::vector<T>> table;
  const U oper;

public:

  disjoint_sparse_table(const U& oper_) 
    : oper(oper_) { }
  disjoint_sparse_table(const std::vector<T>& table_, const U& oper_) 
    : oper(oper_) { build(table_); }

  void build(const std::vector<T>& table_) {
    int height = 0, size = table_.size();
    while ((1 << height) < size) {
      ++height;
    }
    table.resize(height, std::vector<T>(size));
    for (int i = 0; i < size; ++i) {
      table[0][i] = table_[i];
    }
    for (int i = 1; i < height; ++i) {
      int bit = (1 << i);
      for (int l = 0; l < size; l += (bit << 1)) {
        int m = std::min(l + bit, size);
        table[i][m - 1] = table_[m - 1];
        for (int j = m - 2; j >= l; --j) {
          table[i][j] = oper(table_[j], table[i][j + 1]);
        }
        if (m >= size) {
          break;
        }
        table[i][m] = table_[m];
        int r = std::min(m + bit, size);
        for (int j = m + 1; j < r; ++j) {
          table[i][j] = oper(table[i][j - 1], table_[j]);
        }
      }
    }
  }

  T fold(int l, int r) const {
    if (l >= --r) {
      return table[0][l];
    }
    int h = 31 - __builtin_clz(l ^ r);
    return oper(table[h][l], table[h][r]);
  }

};

using modint = modulo_int<>;
using lint = long long;
constexpr lint inf = (1ll << 60) - 1;

int main() {
  int N;
  lint A, B;
  std::cin >> N >> A >> B;
  if (A < B) {
    std::swap(A, B);
  }
  std::vector<lint> value(N + 3);
  value[0] = -inf * 2;
  value[1] = -inf;
  value[N + 2] = inf * 2;
  for (int i: frep(2, N + 2)) {
    std::cin >> value[i];
  }
  std::vector<lint> difference(N + 2);
  for (int i: frep(0, N + 2)) {
    difference[i] = value[i + 1] - value[i];
  }
  auto get_min = [](lint x, lint y) { return x < y ? x : y; };
  disjoint_sparse_table<lint, decltype(get_min)> table(difference, get_min);
  std::vector<modint> dp1(N + 3), dp2(N + 3), sum1(N + 4), sum2(N + 4);
  dp2[1] = 1;
  sum2[2] += 1;
  for (int i: frep(2, N + 3)) {
    sum1[i] += sum1[i - 1];
    sum2[i] += sum2[i - 1];
    if (value[i] - value[i - 1] >= A) {
      dp2[i] += dp1[i - 1] + dp2[i - 1];
    }
    int right = std::min<int>(std::upper_bound(value.begin(), value.end(), value[i] - A) - value.begin(), i - 1);
    int left = [&] {
      if (i == 2) {
        return 1;
      }
      if (table.fold(i - 2, i - 1) < B) {
        return i - 2;
      } 
      if (table.fold(2, i - 1) >= B) {
        return 1;
      }
      int ok = i - 2, ng = 1;
      while (ok - ng > 1) {
        int md = (ok + ng) / 2;
        (table.fold(md, i - 1) >= B ? ok : ng) = md;
      }
      return ok - 1;
    }();
    debug(i, value[i], left, right);
    if (right > left) {
      dp1[i] = sum1[right] - sum1[left] + sum2[right] - sum2[left];
    }
    if (i + 1 < N + 3 && value[i + 1] - value[i - 1] >= B) {
      sum1[i + 1] += dp1[i];
    }
    sum2[i + 1] += dp2[i];
  }
  std::cout << dp1[N + 2] + dp2[N + 2] << '\n';
  return 0;
}


Measured memory_bytes: 18288