input = STDIN.read.split("\n").map{|l| l.split(" ")}

first = input.shift
H = first[1].to_i
W = first[2].to_i

cnt = 0
input.each do |r|
  if r[0].to_i >= H && r[1].to_i >= W 
    cnt = cnt + 1
  end
end

puts cnt