n,m,v,p = gets.split.map &:to_i
as = gets.split.map &:to_i

as_count = {}

as.each{ |a|
	if as_count[a] == nil then
		as_count[a] = 1
	else
		as_count[a] += 1
	end
}

as_key = as_count.keys.sort

sec = as.sort{|a,b| b <=> a}[p-1]
sec_index = as_key.index{ |x| x == sec }

count = as.count { |x| x == sec }

result = 0
res = []

as.each{ |a|
	a_index = as_key.bsearch_index{ |x| x >= a }


	if sec <= a then
		result += 1
		next
	end
	
	diff = sec - a

	total = 0

	as_key[a_index .. sec_index].each{ |aa|
		total += as_count[aa] * (aa - a)
	}
	
	if [diff, (total * 1.0 / (n - v)).ceil].max <= m then
		result += 1
	end
}


puts result