#include <bits/stdc++.h>
using namespace std;
int k[3], n, pos[200005];
int dp[200005][3];
int main() {
  ios::sync_with_stdio(0);
  for (int i = 0; i < 3; i++) cin >> k[i], n += k[i];
  for (int t, p = 0; p < 3; p++)
    for (int i = 1; i <= k[p]; i++) {
      cin >> t, pos[t] = p;
    }
  for (int i = 1; i <= n; i++) {
    dp[i][0] = dp[i - 1][0] + (pos[i] != 0);
    dp[i][1] =
        ((dp[i - 1][0]) < (dp[i - 1][1]) ? (dp[i - 1][0]) : (dp[i - 1][1])) +
        (pos[i] != 1);
    dp[i][2] =
        ((dp[i - 1][0]) < (((dp[i - 1][1]) < (dp[i - 1][2]) ? (dp[i - 1][1])
                                                            : (dp[i - 1][2])))
             ? (dp[i - 1][0])
             : (((dp[i - 1][1]) < (dp[i - 1][2]) ? (dp[i - 1][1])
                                                 : (dp[i - 1][2])))) +
        (pos[i] != 2);
  }
  cout << ((dp[n][0]) < (((dp[n][1]) < (dp[n][2]) ? (dp[n][1]) : (dp[n][2])))
               ? (dp[n][0])
               : (((dp[n][1]) < (dp[n][2]) ? (dp[n][1]) : (dp[n][2]))));
  return 0;
}
