#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, e, f;
  cin >> a >> b >> c >> d >> e >> f;
  b = min(b, c);
  int ans = 0;
  if (e >= f) {
    int tmp = min(a, d);
    ans += e * tmp;
    a -= tmp;
    d -= tmp;
    tmp = min(b, d);
    ans += f * tmp;
  } else {
    int tmp = min(b, d);
    ans += f * tmp;
    d -= tmp;
    ans += e * min(a, d);
  }
  cout << ans << endl;
  return 0;
}
