import java.util.*

fun main(args: Array<String>) {
    val (N, M, V, P) = readLine()!!.split(" ").map{it.toInt()}
    val A = readLine()!!.split(" ").map{it.toLong()}.sorted()

    fun check(p: Int): Boolean {
        val v = A[p] + M

        var rest = M * (V - 1L)
        var cnt = 0L

        val b = ArrayList<Long>()

        for (i in A.indices) {
            if (i == p) continue

            if (A[i] > v) {
                rest -= M
                cnt++
            } else if (v - A[i] < M) {
                rest -= v - A[i]
                b.add(M - (v - A[i]))
            } else {
                rest -= M.toLong()
            }
        }

        b.sortDescending()

        for (t in b) {
            if (rest <= 0) break
            cnt++
            rest -= t
        }

        return cnt <= P - 1
    }

    var l = -1
    var u = N - 1

    while (u - l > 1) {
        val c = (l + u) / 2

        if (check(c)) {
            u = c
        } else {
            l = c
        }
    }

    println(N - u)
}
