import java.io.*;
import java.util.*;

/**
 * Created by Ayushi on 03 May 2020.
 * Problem:
 * Round:
 */

public class Main {
    public static void main(String[] args) throws IOException {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    }
} import java.io.*; io.* java import java.util.*; util.* java public class Main {
    public static void main(String[] args) throws IOException {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    }
} Main public static void main(String[] args) throws IOException {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    } main {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    } StringTokenizer st; st BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) st = new StringTokenizer(br.readLine(), " ") st new StringTokenizer(br.readLine(), " ") int n = Integer.parseInt(st.nextToken()); n Integer.parseInt(st.nextToken()) Integer.parseInt Integer st.nextToken() st.nextToken st int k = Integer.parseInt(st.nextToken()); k Integer.parseInt(st.nextToken()) Integer.parseInt Integer st.nextToken() st.nextToken st ArrayList<String> arr = new ArrayList<>(); arr new ArrayList<>() for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        } int i = 1; int i = 1; i 1 i <= n i n i++ i++ i {
            arr.add(String.valueOf(i));
        } {
            arr.add(String.valueOf(i));
        } arr.add(String.valueOf(i)) arr.add arr String.valueOf(i) String.valueOf String i String a; a for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        } int j = 0; int j = 0; j 0 j < k j k j++ j++ j {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        } {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        } int d = Integer.parseInt(br.readLine()); d Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br st = new StringTokenizer(br.readLine()) st new StringTokenizer(br.readLine()) while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            } st.hasMoreTokens() st.hasMoreTokens st {
                a = st.nextToken();
                arr.remove(a);
            } a = st.nextToken() a st.nextToken() st.nextToken st arr.remove(a) arr.remove arr a br.close() br.close br System.out.println(arr.size()) System.out.println System.out System System.out arr.size() arr.size arr String[] args args public class Main {
    public static void main(String[] args) throws IOException {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    }
} public class Main {
    public static void main(String[] args) throws IOException {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    }
} Main
import java.io.*;
import java.util.*;

/**
 * Created by Ayushi on 03 May 2020.
 * Problem:
 * Round:
 */

public class Main {
    public static void main(String[] args) throws IOException {
        StringTokenizer st;
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        st = new StringTokenizer(br.readLine(), " ");
        int n = Integer.parseInt(st.nextToken());
        int k = Integer.parseInt(st.nextToken());
        ArrayList<String> arr = new ArrayList<>();
        for (int i = 1; i <= n; i++) {
            arr.add(String.valueOf(i));
        }
        String a;
        for (int j = 0; j < k; j++) {
            int d = Integer.parseInt(br.readLine());
            st = new StringTokenizer(br.readLine());
            while (st.hasMoreTokens()) {
                a = st.nextToken();
                arr.remove(a);
            }
        }
        br.close();
        System.out.println(arr.size());
    }
}
