#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, e, f;
  scanf("%d%d%d%d%d%d", &a, &b, &c, &d, &e, &f);
  int ans = 0;
  if (e > f) {
    int num1 = min(a, d);
    int num2 = min(d - num1, min(b, c));
    ans += num1 * e + num2 * f;
  } else {
    int num2 = min(min(b, c), d);
    int num1 = min(d - num2, a);
    ans += num1 * e + num2 * f;
  }
  printf("%d", ans);
}
