#include <bits/stdc++.h>
using namespace std;
long long a[100005], b[100005];
int main() {
  long long i, n, m, a1 = 0, a2 = 0, b1 = 0, b2 = 0;
  cin >> n >> m;
  for (i = 0; i < n; ++i) {
    cin >> a[i];
    a1 += a[i];
  }
  for (i = 0; i < m; ++i) {
    cin >> b[i];
    a2 += b[i];
  }
  sort(a, a + n);
  sort(b, b + m);
  for (i = 0, b1 += a2; i < n - 1; ++i) {
    b1 += min(a[i], a2);
  }
  for (i = 0, b2 += a1; i < m - 1; ++i) {
    b2 += min(b[i], a1);
  }
  cout << min(b1, b2) << "\n";
  return 0;
}
