#include <bits/stdc++.h>
using namespace std;
int cnt = 0, mini = 1e9, maxi = -1;
int mini1 = 1e9, maxi1 = -1, cnt1 = 0, cnt2 = 0;
int main() {
  ios_base::sync_with_stdio(0);
  int a, b, c, d, e, f;
  cin >> a >> b >> c >> d >> e >> f;
  if (e >= f) {
    int g, h;
    g = min(a, d);
    d -= g;
    h = min(b, min(c, d));
    cout << g * e + h * f;
  }
  if (e < f) {
    int g, h;
    h = min(b, min(c, d));
    d -= h;
    g = min(a, d);
    cout << g * e + h * f;
  }
}
