#include<stdio.h>

int main(void){
  int sunuke, okashi, holder, memory[101], check, tmp;
  int i, j;
  
  scanf("%d" "%d", &sunuke, &okashi);
  for(i = 0; i < sunuke; i++){
    memory[i] = -1;
  }
  check = 0;
  
  for(i = 1; i<=okashi; i++){
    scanf("%d", &holder);
    for(j = 1; i <= holder; j++){
      scanf("%d",&tmp);
      if(tmp != memory[tmp]){
        check++;
        memory[tmp] = tmp;
      }
    }
  }
  
  sunuke = sunuke - check;
  printf("%d\n", sunuke);
  
  return 0;
}