2. Make a C++ program that will calculate the total expenses and Cash left of Miss Carla after spending the following :
Cash - 4,050.00
B&W perfume - 700.50
B&W lotion - 560.85
Dresses - 2072.50
Note : the program must display the cash left and total expenses.
#include<iostream>
using namespace std;
int main()
{
float Cash = 4050;
float BWpar = 700.5;
float BWLot = 560.85;
float Dresses = 2072.5;
float TotExp = BWpar + BWLot + Dresses;
float CashLeft = Cash - TotExp;
cout << "The total expenses of Miss Carla are " << TotExp;
cout << "\nThe cash left is " << CashLeft;
}
Comments
Leave a comment