#include <iostream>
#include<vector>
#include<algorithm>
#include<string>
#include<map>
#include<set>
#include<stack>
#include<queue>
#include<math.h>
using namespace std;
typedef long long ll;
#define int long long
typedef vector<int> VI;
typedef pair<int, int> pii;
#define fore(i,a) for(auto &i:a)
#define REP(i,n) for(int i=0;i<n;i++)
#define eREP(i,n) for(int i=0;i<=n;i++)
#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define eFOR(i,a,b) for(int i=(a);i<=(b);++i)
#define SORT(c) sort((c).begin(),(c).end())
#define rSORT(c) sort((c).rbegin(),(c).rend())
#define LB(x,a) lower_bound((x).begin(),(x).end(),(a))
#define UB(x,a) upper_bound((x).begin(),(x).end(),(a))
#define INF 1000000000
#define LLINF 9223372036854775807
#define mod 1000000007
//vector<vector<int> > dp;
//vector<vector<vector<int> > > vvvi;
//dp=vector<vector<int> >(N, vector<int>(M,0));
//vector<pair<int,int> > v;
//v.push_back(make_pair(x,y));
//priority_queue<int,vector<int>, greater<int> > q2;



signed main(){
cin.tie(0);
ios::sync_with_stdio(false);

	int N;
	cin >> N;
	int P[110][3] = { 0 };
	int X;
	cin >> X;
	REP(i, X) {
		int a;
		cin >> a;
		P[a][0] = 1;
	}
	cin >> X;
	REP(i, X) {
		int a;
		cin >> a;
		P[a][1] = 1;
	}
	cin >> X;
	REP(i, X) {
		int a;
		cin >> a;
		P[a][2] = 1;
	}
	int ans = 0;
	eFOR(i, 1, N) {
		if (P[i][1] == P[i][2] && P[i][1] == 1) {
			ans++;
		}
		else if (P[i][0]==0 && P[i][2]==1) {
			ans++;
		}
	}

	cout << ans << endl;
	return 0;
}


