import java.util.Scanner;
import java.util.*;


public class Main {
    public static void main(String args[]){
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    }

} import java.util.Scanner; Scanner java.util import java.util.*; util.* java public class Main {
    public static void main(String args[]){
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    }

} Main public static void main(String args[]){
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    } main {
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    } Set<Integer> set = new HashSet<Integer>(); set new HashSet<Integer>() 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 dCount = 0; dCount 0 while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        } dCount < k dCount k {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        } int d = sc.nextInt(); d sc.nextInt() sc.nextInt sc for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            } int i = 0; int i = 0; i 0 i < d i d i++ i++ i {
                set.add(sc.nextInt());
            } {
                set.add(sc.nextInt());
            } set.add(sc.nextInt()) set.add set sc.nextInt() sc.nextInt sc dCount++ dCount System.out.print(n - set.size()) System.out.print System.out System System.out n - set.size() n set.size() set.size set String args[] args public class Main {
    public static void main(String args[]){
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    }

} public class Main {
    public static void main(String args[]){
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    }

} Main
import java.util.Scanner;
import java.util.*;


public class Main {
    public static void main(String args[]){
        Set<Integer> set = new HashSet<Integer>();

        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int k = sc.nextInt();

        int dCount = 0;

        while(dCount < k) {
            int d = sc.nextInt();
            for(int i = 0;i < d;i++){
                set.add(sc.nextInt());
            }
            dCount++;
        }

        System.out.print(n - set.size());
    }

}
