program division_into_two
  implicit none
  integer(8), parameter :: md = 1000000007_8
  integer :: n, i, k = 2, x(0:100000) = 0
  integer(8) :: a, b, s(100000) = 0_8, y(100001) = 0_8
  read(*,*) n, a, b
  if (n == 1) then
    write(*,'(i0)') 2
    stop
  end if
  do i = 1, n
    read(*,*) s(i)
  end do
  if (a > b) then
    a = xor(a,b)
    b = xor(a,b)
    a = xor(a,b)
  end if
  do i = 1, n-2
    if (s(i+2)-s(i) < a) then
      write(*,'(i0)') 0
      stop
    end if
  end do
  do i = 2, n
    x(i) = x(i-1)
    if (s(i)-s(i-1) < a) x(i) = x(i)+1
  end do
  y(1) = 1_8
  do i = 1, n
    do while (k <= n .and. s(k)-s(i) < b)
      k = k+1
    end do
    if (x(i) == x(i-1)) y(i+1) = mod(y(i+1)+y(i),md)
    if (k == i+1 .or. x(k-1) == x(i+1)) y(k) = mod(y(k)+y(i),md)
  end do
  write(*,'(i0)') y(n+1)
end program division_into_two