#include <bits/stdc++.h>
using namespace std;
int LinearSearch(int x, int S[], int N) {
  S[N] = x;
  for (int i = 0;; i++) {
    if (S[i] == x)
      if (i < N) {
        return i;
      } else
        return -1;
  }
}
int main() {
  int N, X, Y, Z;
  int a[100] = {0};
  int b[100] = {0};
  int c[100] = {0};
  int count = 0;
  cin >> N;
  cin >> X;
  for (int i = 0; i < X; i++) {
    cin >> a[i];
  }
  cin >> Y;
  for (int i = 0; i < Y; i++) {
    cin >> b[i];
  }
  cin >> Z;
  for (int i = 0; i < Z; i++) {
    cin >> c[i];
    if (LinearSearch(c[i], a, X) == -1) count++;
  }
  cout << count << endl;
  return 0;
}
