import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		}
} import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		} main {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		} 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 List<Integer> list = new ArrayList<>(); list new ArrayList<>() for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		} int i =0; int i =0; i 0 i < K i K i++ i++ i {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		} {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		} int d = sc.nextInt(); d sc.nextInt() sc.nextInt sc for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			} int num = 0; int num = 0; num 0 num < d num d num++ num++ num {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			} {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			} int kos = sc.nextInt(); kos sc.nextInt() sc.nextInt sc if(!list.contains(kos)) {
					 list.add(kos);
				} !list.contains(kos) list.contains(kos) list.contains list kos {
					 list.add(kos);
				} list.add(kos) list.add list kos System.out.println(N-list.size()) System.out.println System.out System System.out N-list.size() N list.size() list.size list String[] args args public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		}
} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		}
} Main
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int N = sc.nextInt();
		int K = sc.nextInt();
		 List<Integer> list = new ArrayList<>();
		for(int i =0; i < K; i++) {
			int d = sc.nextInt();
			for(int num = 0; num < d; num++ ) {
				int kos = sc.nextInt();
				if(!list.contains(kos)) {
					 list.add(kos);
				}

			}
		}
			System.out.println(N-list.size());
		}
}
