#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, e, f, mn1, mn2, res, ans1, ans2;
  cin >> a >> b >> c >> d >> e >> f;
  res = d;
  mn2 = min(b, min(c, d));
  d = abs(mn2 - d);
  mn1 = min(a, d);
  ans1 = (mn2 * f) + (mn1 * e);
  mn1 = min(a, res);
  res = abs(mn1 - res);
  mn2 = min(b, min(c, res));
  ans2 = (mn2 * f) + (mn1 * e);
  cout << max(ans1, ans2) << endl;
}
