'use strict';
const main = arg => {
  const input = arg.trim().split('\n');
  const arr = input.map(a => a.split(' '));
  // console.log(arr);
  const N = arr[0][0];

  let rowArray = [];
  // console.log(arr.length)
  for (let i=2; i<arr.length; i+=2) {
    rowArray.push(arr[i]);
    // console.log(arr[i]);
  }
  // console.log(rowArray.flat());

  const set = new Set(rowArray.flat());
  const AnswerArr = Array.from(set);

  console.log(N - AnswerArr.length);
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));