object Main extends App {
  import scala.io.StdIn._
  
  val Array(n,k) = readLine.split(" ").map{_.toInt}.toArray
  val check = Array.fill(n+1)(false)
  check(0) = true
                              
  for (i <- 1 to k) {
    val d = readInt
    val a = readLine.split(" ").map{_.toInt}.toList
    a.foreach{x => check(x) = true}
  }
  
  println(check.count{x => !x})
                                         
}