#include <iostream> #include <cstdio> using namespace std; int main() { int num1,num2; double a1,b1,a2,b2; cin >>num1>>a1>>b1>>num2>>a2>>b2; printf ("VALOR A PAGAR: R$ %.2f", a1* b1 + a2*b2); return 0; }