
func readArrayInt() -> [Int] {
    readLine()!.split(separator: " ").map({Int($0)!})
}

let line = readArrayInt()
let (N, K) = (line[0], line[1])
var sunukes: Set<Int> = []
(1...N).forEach({sunukes.insert($0)})
for _ in 1...K {
    _ = readLine()
    readArrayInt().forEach({sunukes.remove($0)})
}
print(sunukes.count)
