import java.util.*;
import java.math.*;
public class Main {
	public static void main(String[] args){
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	}
} import java.util.*; util.* java import java.math.*; math.* java public class Main {
	public static void main(String[] args){
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	}
} Main public static void main(String[] args){
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	} main {
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc int K = sc.nextInt(); K sc.nextInt() sc.nextInt sc List<Integer> a = new ArrayList<>(); a new ArrayList<>() for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        } int i = 0; int i = 0; i 0 i < K i K i++ i++ i {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        } {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        } int d = sc.nextInt(); d sc.nextInt() sc.nextInt sc for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            } int j = 0 ; int j = 0 ; j 0 j < d j d j++ j++ j {
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            } {
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            } int c = sc.nextInt(); c sc.nextInt() sc.nextInt sc if (!a.contains(c))	a.add(c); !a.contains(c) a.contains(c) a.contains a c a.add(c) a.add a c System.out.println(N - a.size()) System.out.println System.out System System.out N - a.size() N a.size() a.size a String[] args args public class Main {
	public static void main(String[] args){
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	}
} public class Main {
	public static void main(String[] args){
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	}
} Main
import java.util.*;
import java.math.*;
public class Main {
	public static void main(String[] args){
		
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		int K = sc.nextInt();
       // int d = new int[K];
       List<Integer> a = new ArrayList<>();
        for (int i = 0; i < K; i++) {
            int d = sc.nextInt();
			for (int j = 0 ; j < d ;j++){
				int c = sc.nextInt();
			if (!a.contains(c))	a.add(c);
            }
        }
		System.out.println(N - a.size());
	}
}