function main (input) {
	var input = input.split(' ');
	var A = parseInt(input[0], 10);
	var B = parseInt(input[1], 10);
	var C = parseInt(input[2], 10);
	var x = parseInt(input[3], 10);
	var y = parseInt(input[4], 10);
	var priceA = 0;
	var priceB = 0;
    var priceC = 0;
    var price = [];

	priceA = x * A + y * B;
    price.push(priceA);
    priceB = x > y ? C * 2 * y + A * (x - y) : C * 2 * x + B * (y - x);
	price.push(priceB);
    priceC = x > y ? C * 2 * x : C * 2 * y;
    price.push(priceC);
    console.log(Math.min.apply(null, price));
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));