program widespread
  implicit none
  integer :: n, i
  integer(8) :: a, b, h(100000), btm, top, mid, t, s
  h = 0_8
  read(*,*) n, a, b
  do i = 1, n
    read(*,*) h(i)
  end do
  btm = 0_8
  top = maxval(h(1:n))/b
  do while (top-btm.gt.1_8)
    mid = (top+btm)/2_8
    s = b*mid
    t = 0_8
    do i = 1, n
      if (h(i).le.s) cycle
      t = t + (h(i)-s)/(a-b)
      if (mod(h(i)-s,a-b).ne.0_8) t = t + 1_8
    end do
    if (t.gt.mid) then
      btm = mid
    else
      top = mid
    end if
  end do
  write(*,'(i0)') top
  stop
end program widespread