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