#include <bits/stdc++.h>
using namespace std;
int vis[200005];
int dp[200005][4];
int main() {
  int a, b, c;
  scanf("%d%d%d", &a, &b, &c);
  for (int i = 1; i <= a; i++) {
    int x;
    scanf("%d", &x);
    vis[x] = 1;
  }
  for (int i = 1; i <= b; i++) {
    int x;
    scanf("%d", &x);
    vis[x] = 2;
  }
  for (int i = 1; i <= c; i++) {
    int x;
    scanf("%d", &x);
    vis[x] = 3;
  }
  int n = a + b + c;
  int k = vis[1];
  dp[1][1] = dp[1][2] = dp[1][3] = 1;
  dp[1][k]--;
  for (int i = 2; i <= n; i++) {
    int t1 = dp[i - 1][1], t2 = dp[i - 1][2], t3 = dp[i - 1][3];
    k = vis[i];
    dp[i][1] = dp[i - 1][1] + 1;
    dp[i][2] = min(dp[i - 1][1], dp[i - 1][2]) + 1;
    dp[i][3] = min(dp[i - 1][1], min(dp[i - 1][2], dp[i - 1][3])) + 1;
    dp[i][k]--;
  }
  printf("%d\n", min(dp[n][1], min(dp[n][2], dp[n][3])));
  return 0;
}
