
import java.util.Scanner;

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];
        int[] A = new int[N];
        boolean[] Sunuke = new boolean[N];
        int ans = 0;
        
        for(int i = 0; i < K; i++) {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        }
        
        for(int i = 0; i < N; i++) {
        	if(Sunuke[i] == false) ans++; 
        }
        
        System.out.println(ans);

 

        
        }
	}
 import java.util.Scanner; Scanner java.util 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];
        int[] A = new int[N];
        boolean[] Sunuke = new boolean[N];
        int ans = 0;
        
        for(int i = 0; i < K; i++) {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        }
        
        for(int i = 0; i < N; i++) {
        	if(Sunuke[i] == false) ans++; 
        }
        
        System.out.println(ans);

 

        
        }
	} 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];
        int[] A = new int[N];
        boolean[] Sunuke = new boolean[N];
        int ans = 0;
        
        for(int i = 0; i < K; i++) {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        }
        
        for(int i = 0; i < N; i++) {
        	if(Sunuke[i] == false) ans++; 
        }
        
        System.out.println(ans);

 

        
        } main {
        Scanner sc = new Scanner(System.in);
        int N = sc.nextInt();
        int K =sc.nextInt();
        int[] d = new int[K];
        int[] A = new int[N];
        boolean[] Sunuke = new boolean[N];
        int ans = 0;
        
        for(int i = 0; i < K; i++) {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        }
        
        for(int i = 0; i < N; i++) {
        	if(Sunuke[i] == false) ans++; 
        }
        
        System.out.println(ans);

 

        
        } 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 int[] d = new int[K]; d new int[K] K int[] A = new int[N]; A new int[N] N boolean[] Sunuke = new boolean[N]; Sunuke new boolean[N] N int ans = 0; ans 0 for(int i = 0; i < K; i++) {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        } int i = 0; int i = 0; i 0 i < K i K i++ i++ i {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        } {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        } d[i] = sc.nextInt() d[i] d i sc.nextInt() sc.nextInt sc for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	} int j = 0; int j = 0; j 0 j < d[i] j d[i] d i j++ j++ j {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	} {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	} A[j] = sc.nextInt() A[j] A j sc.nextInt() sc.nextInt sc Sunuke[A[j]-1] = true Sunuke[A[j]-1] Sunuke A[j]-1 A[j] A j 1 true for(int i = 0; i < N; i++) {
        	if(Sunuke[i] == false) ans++; 
        } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
        	if(Sunuke[i] == false) ans++; 
        } {
        	if(Sunuke[i] == false) ans++; 
        } if(Sunuke[i] == false) ans++; Sunuke[i] == false Sunuke[i] Sunuke i false ans++ ans System.out.println(ans) System.out.println System.out System System.out ans String[] args args

import java.util.Scanner;

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];
        int[] A = new int[N];
        boolean[] Sunuke = new boolean[N];
        int ans = 0;
        
        for(int i = 0; i < K; i++) {
        	d[i] = sc.nextInt();
        	for(int j = 0; j < d[i]; j++) {
        		A[j] = sc.nextInt();
        		Sunuke[A[j]-1] = true;
        	}
        }
        
        for(int i = 0; i < N; i++) {
        	if(Sunuke[i] == false) ans++; 
        }
        
        System.out.println(ans);

 

        
        }
	}

