Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- int main()
- {
- int product1_code,product1_unit,product2_code,product2_unit;
- double product1_price,product2_price,total;
- scanf("%d%d%",& product1_code,&product1_unit);
- scanf("%lf",&product1_price);
- scanf("%d%d%",& product2_code,&product2_unit);
- scanf("%lf",&product2_price);
- total=product1_unit *product1_price+product2_unit*product2_price;
- printf("VALOR TO PAGAR: %.2lf\n",total);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement