#include<iostream>
#include<iomanip>
#include<cmath>
#include<vector>
#include<algorithm>
#include<string>
#include<stack>
#include<deque>
#include<map>
#include<queue>
#include<iterator>
#include<set>

using namespace std;
#define ll long long
#define endl "\n"
const int dx[] = { -1 , -1 , -1 , 0 , 0 , 0 , 1 , 1 , 1 };
const int dy[] = { -1 , 0 , 1 , -1 , 0 , 1 , -1 , 0 , 1 };
#define N 8010000
#define TC int t;cin>>t;for(int T=1;T<=t;T++)
#define mod 1000000007
#define PI acos(-1)
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
void AIA() { ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0); }
//cout<<fixed<<setprecision(20);
// freopen("stand.in","r",stdin);
// freopen("stand.out","w",stdout);

/*
			 __               _____________                __                        _____________              __                ___        ___       ___________________________     ____        ____
			/\ \             |_____   _____|              /\ \                      |             |            /\ \              |   |      |   |     |                           |    \   \      /   /
		   / /\ \                  | |                   / /\ \                     |   __________|           / /\ \             |   |      |   |     |      _____      _____     |     \   \    /   /
		  / /  \ \                 | |                  / /  \ \                    |  |                     / /  \ \            |   |      |   |     |     |     |    |     |    |      \   \  /   /
		 / /    \ \                | |                 / /    \ \                   |  |                    / /    \ \           |   |      |   |     |     |     |    |     |    |       \   \/   /
		/ /      \ \               | |                / /      \ \                  |  |______             / /      \ \          |   |______|   |     |     |     |    |     |    |        \      /
	   / /        \ \              | |               / /        \ \                 |         |           / /        \ \         |              |     |     |     |    |     |    |         \    /
	  / /          \ \             | |              / /          \ \                |   ______|          / /          \ \        |    ______    |     |     |     |    |     |    |          |  |
	 / /============\ \            | |             / /============\ \               |  |                / /============\ \       |   |      |   |     |     |     |    |     |    |          |  |
	/ /==============\ \           | |            / /==============\ \              |  |               / /==============\ \      |   |      |   |     |     |     |    |     |    |          |  |
   / /                \ \          | |           / /                \ \             |  |              / /                \ \     |   |      |   |     |     |     |    |     |    |          |  |
  / /                  \ \    _____| |_____     / /                  \ \            |  |             / /                  \ \    |   |      |   |     |     |     |    |     |    |          |  |
 /_/                    \_\  |_____________|   /_/                    \_\ _________ |__|            /_/                    \_\   |___|      |___|     |_____|     |____|     |____|          |__|

																	  <<<<<<<<<<< NEVER GIVE UP !! >>>>>>>>>>>
																	<<<<<<<< YOU CAN DO IT IF YOU WANT !! >>>>>>>>
																	 <<<<<<<<< BELIEVE IN YOURSELF !! >>>>>>>>>
__________________________________________________
|__________________            __________________|
|                 |\          /|                 |
|                 | \        / |                 |
|                 |  \      /  |                 |
|=====================|\__/|=====================|
|=====================|/  \|=====================|
|                 |  /      \  |                 |
|                 | /        \ |                 |
|_________________|/          \|_________________|
|________________________________________________|

*/

int main()
{
	//cout<<fixed<<setprecision(20);
	//freopen("stand.in","r",stdin);
	//freopen("stand.out","w",stdout);
	AIA();
	int n, k;
	cin >> n >> k;
	vector<int>num(n+1);
	map<int, int>mp1;
	for (int i = 1; i <= n; i++) {
		num[i] = i;
	}

	for (int i = 0; i < k; i++) {
		int di;
		cin >> di;
		for (int j = 0; j < di; j++) {
			int x;
			cin >> x;
			mp1[x] = 1;
		}
	}
	int c=0;
	for (int i = 1; i <= n; i++) {
		if (mp1[num[i]] == 0) {
			c++;
		}
	}
	cout << c;
	return 0;
}







Measured memory_bytes: 3616