import java.util.Scanner;

public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    }
} Main public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    } main {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) String newLine; newLine int ppl ppl snackKind snackKind havingSnackTotal havingSnackTotal treated; treated boolean hasSnack[]; hasSnack ppl = scan.nextInt() ppl scan.nextInt() scan.nextInt scan snackKind = scan.nextInt() snackKind scan.nextInt() scan.nextInt scan newLine = scan.nextLine() newLine scan.nextLine() scan.nextLine scan hasSnack = new boolean[ppl] hasSnack new boolean[ppl] ppl for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        } int i = 0; int i = 0; i 0 i < hasSnack.length i hasSnack.length hasSnack hasSnack.length i++ i++ i {
            hasSnack[i] = false;
        } {
            hasSnack[i] = false;
        } hasSnack[i] = false hasSnack[i] hasSnack i false for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        } int k = 0; int k = 0; k 0 k < snackKind k snackKind k++ k++ k {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        } {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        } havingSnackTotal = scan.nextInt() havingSnackTotal scan.nextInt() scan.nextInt scan newLine = scan.nextLine() newLine scan.nextLine() scan.nextLine scan for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            } int p = 0; int p = 0; p 0 p < havingSnackTotal p havingSnackTotal p++ p++ p {
                hasSnack[scan.nextInt() - 1] = true;
            } {
                hasSnack[scan.nextInt() - 1] = true;
            } hasSnack[scan.nextInt() - 1] = true hasSnack[scan.nextInt() - 1] hasSnack scan.nextInt() - 1 scan.nextInt() scan.nextInt scan 1 true newLine = scan.nextLine() newLine scan.nextLine() scan.nextLine scan treated = 0 treated 0 for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        } int i = 0; int i = 0; i 0 i < hasSnack.length i hasSnack.length hasSnack hasSnack.length i++ i++ i {
            if(!hasSnack[i]) {
                treated++;
            }
        } {
            if(!hasSnack[i]) {
                treated++;
            }
        } if(!hasSnack[i]) {
                treated++;
            } !hasSnack[i] hasSnack[i] hasSnack i {
                treated++;
            } treated++ treated System.out.println(treated) System.out.println System.out System System.out treated scan.close() scan.close scan return; String args[] args public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    }
} public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String args[]) {
        Scanner scan = new Scanner(System.in);
        String newLine;
        int ppl, snackKind, havingSnackTotal, treated;
        boolean hasSnack[];

        ppl = scan.nextInt();
        snackKind = scan.nextInt();
        newLine = scan.nextLine();
        
        hasSnack = new boolean[ppl];
        for(int i = 0; i < hasSnack.length; i++) {
            hasSnack[i] = false;
        }

        for(int k = 0; k < snackKind; k++) {
            havingSnackTotal = scan.nextInt();
            newLine = scan.nextLine();
            
            for(int p = 0; p < havingSnackTotal; p++) {
                hasSnack[scan.nextInt() - 1] = true;
            }
            newLine = scan.nextLine();
        }

        treated = 0;
        for(int i = 0; i < hasSnack.length; i++) {
            if(!hasSnack[i]) {
                treated++;
            }
        }
        System.out.println(treated);
        scan.close();
        return;
    }
}