nhw = gets.split

nhw.map!{|a| a.to_i}

n=nhw[0]
h=nhw[1]
w=nhw[2]
array = Array.new
for i in (0..n-1)
    ab=gets.split.map{|a|a.to_i}
    array.push(ab)
end

m=0
array.each do |a|
  if (a[0] >=h && a[1]>= w)
    m +=1
  end
end
p m
