#include <iostream>

using namespace std;

int main() {
    int n1, n2, n3;
    long long sum1 = 0, sum2 = 0, sum3 = 0, mi1 = INT_MAX, mi2 = INT_MAX, mi3 = INT_MAX;
    cin >> n1 >> n2 >> n3;
    for (int i = 0; i < n1; i++) {
        int a;
        cin >> a;
        if (a < mi1) {
            mi1 = a;
        }
        sum1 += a;
    }
    for (int i = 0; i < n2; i++) {
        int a;
        cin >> a;
        if (a < mi2) {
            mi2 = a;
        }
        sum2 += a;
    }
    for (int i = 0; i < n3; i++) {
        int a;
        cin >> a;
        if (a < mi3) {
            mi3 = a;
        }
        sum3 += a;
    }
    long long min_all = min(mi1 + mi2, min(mi1 + mi3, mi2 + mi3));
    long long minus = min(min_all, min(sum1, min(sum2, sum3)));
    cout << sum1 + sum2 + sum3- 2 * minus;
    return 0;
}