#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
const long long int INF = 1e18;
int main() {
  int a, b, c, d, e, f;
  cin >> a >> b >> c >> d >> e >> f;
  long long int ans = 0;
  if (f >= e) {
    ans += f * min(min(b, c), d);
    d = d - min(min(b, c), d);
    ans += e * min(a, d);
  } else if (e > f) {
    ans += e * min(a, d);
    d = d - min(a, d);
    ans += f * min(min(b, c), d);
  }
  cout << ans;
  return 0;
}
