import kotlin.math.*
import java.util.*

fun main(args: Array<String>) {
  val (n, k) = readLine()!!.split(' ').map(String::toInt)
  val snk = (1..n).toMutableSet()
  repeat(k) {
    readLine()
    readLine()!!.split(' ').map(String::toInt).forEach { snk.remove(it) }
  }
  println(snk.size)
}
