import java.util.*;

public class Main {
    public static void main(String[] args){
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args){
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    }
} Main public static void main(String[] args){
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    } main {
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    } Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int N = scanner.nextInt(); N scanner.nextInt() scanner.nextInt scanner int K = scanner.nextInt(); K scanner.nextInt() scanner.nextInt scanner int[] a = new int[N]; a new int[N] N for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        } int i=0; int i=0; i 0 i<N i N i++ i++ i {
            
            a[i] = 1;
            
        } {
            
            a[i] = 1;
            
        } a[i] = 1 a[i] a i 1 for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        } int i=0; int i=0; i 0 i<K i K i++ i++ i {
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        } {
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        } int d = scanner.nextInt(); d scanner.nextInt() scanner.nextInt scanner for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            } int j=0; int j=0; j 0 j<d j d j++ j++ j {
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            } {
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            } int A = scanner.nextInt(); A scanner.nextInt() scanner.nextInt scanner int X = A-1; X A-1 A 1 a[X] = 0 a[X] a X 0 int Sum = 0; Sum 0 for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        } int i=0; int i=0; i 0 i<N i N i++ i++ i {
            
            Sum += a[i];
            
        } {
            
            Sum += a[i];
            
        } Sum += a[i] Sum a[i] a i System.out.println(Sum) System.out.println System.out System System.out Sum String[] args args public class Main {
    public static void main(String[] args){
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    }
} public class Main {
    public static void main(String[] args){
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    }
} Main
import java.util.*;

public class Main {
    public static void main(String[] args){
        
        Scanner scanner = new Scanner(System.in);
        int N = scanner.nextInt();
        int K = scanner.nextInt();
        int[] a = new int[N]; 
        
        for(int i=0; i<N; i++){
            
            a[i] = 1;
            
        }
        
        for(int i=0; i<K; i++){
            
            int d = scanner.nextInt();
            
            for(int j=0; j<d; j++){
                
                int A = scanner.nextInt();
                int X = A-1;
                
                a[X] = 0; 
                
            }
            
        }
        
        int Sum = 0;
        
        for(int i=0; i<N; i++){
            
            Sum += a[i];
            
        }
        
        System.out.println(Sum);
        
    }
}
