#include <bits/stdc++.h>
using namespace std;
function<void(void)> ____ = []() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
};
int a, b, c, d, e, f;
int main() {
  ____();
  cin >> a >> b >> c >> d >> e >> f;
  int ma = a;
  int mb = min(b, c);
  if (e < f) {
    swap(e, f);
    swap(ma, mb);
  }
  int res = 0;
  res += e * min(d, ma);
  d -= min(d, ma);
  res += f * min(d, mb);
  cout << res << endl;
  return 0;
}
