import Control.Monad

inpr::[Int]->[Int]->Int
inpr ls1 ls2= (sum.(map (\(x,y)-> x*y))) (zip ls1 ls2)

solver::[Int]->Int->[[Int]]->Int
solver b c = length.filter (\ans -> (inpr ans b)+c > 0)

main::IO()
main=do
  (n:b:c:[])<-return.map read.words=<<getLine
  b<-return.map read.words=<<getLine
  anss<- forM [1..n] (\_-> return.map read.words=<<getLine)
  print (solver b c anss)
