import java.util.Scanner;
import java.util.HashSet;
import java.util.Set;

class Main{
      public static void main(String args[]){
	Scanner sc = new Scanner(System.in);
	int amt = sc.nextInt();
	int kind = sc.nextInt();
	Set<Integer> st = new HashSet<Integer>();
	for(int i=0;i<kind;i++){
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	}
	System.out.println(amt-st.size());
      }
} import java.util.Scanner; Scanner java.util import java.util.HashSet; HashSet java.util import java.util.Set; Set java.util class Main{
      public static void main(String args[]){
	Scanner sc = new Scanner(System.in);
	int amt = sc.nextInt();
	int kind = sc.nextInt();
	Set<Integer> st = new HashSet<Integer>();
	for(int i=0;i<kind;i++){
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	}
	System.out.println(amt-st.size());
      }
} Main public static void main(String args[]){
	Scanner sc = new Scanner(System.in);
	int amt = sc.nextInt();
	int kind = sc.nextInt();
	Set<Integer> st = new HashSet<Integer>();
	for(int i=0;i<kind;i++){
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	}
	System.out.println(amt-st.size());
      } main {
	Scanner sc = new Scanner(System.in);
	int amt = sc.nextInt();
	int kind = sc.nextInt();
	Set<Integer> st = new HashSet<Integer>();
	for(int i=0;i<kind;i++){
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	}
	System.out.println(amt-st.size());
      } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int amt = sc.nextInt(); amt sc.nextInt() sc.nextInt sc int kind = sc.nextInt(); kind sc.nextInt() sc.nextInt sc Set<Integer> st = new HashSet<Integer>(); st new HashSet<Integer>() for(int i=0;i<kind;i++){
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	} int i=0; int i=0; i 0 i<kind i kind i++ i++ i {
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	} {
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	} int num = sc.nextInt(); num sc.nextInt() sc.nextInt sc for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    } int j=0; int j=0; j 0 j<num j num j++ j++ j {
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    } {
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    } int tmp = sc.nextInt(); tmp sc.nextInt() sc.nextInt sc Integer id = new Integer(tmp); id new Integer(tmp) st.add(id) st.add st id System.out.println(amt-st.size()) System.out.println System.out System System.out amt-st.size() amt st.size() st.size st String args[] args
import java.util.Scanner;
import java.util.HashSet;
import java.util.Set;

class Main{
      public static void main(String args[]){
	Scanner sc = new Scanner(System.in);
	int amt = sc.nextInt();
	int kind = sc.nextInt();
	Set<Integer> st = new HashSet<Integer>();
	for(int i=0;i<kind;i++){
	    int num = sc.nextInt();
	    for(int j=0;j<num;j++){
        int tmp = sc.nextInt();
		Integer id = new Integer(tmp);
		st.add(id);
	    }
	}
	System.out.println(amt-st.size());
      }
}