-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhousing-bills.cpp
More file actions
27 lines (25 loc) · 1.01 KB
/
housing-bills.cpp
File metadata and controls
27 lines (25 loc) · 1.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include <iostream>
#include <iomanip>
#include <string>
using namespace std;
int main()
{
double rOrM, phoneBill, utilities, cable, total;
cout << "Housing bills calculator from @CodeMaster7000 Studios." << endl << endl;
cout << "Enter your monthly rent/mortgage payment: USD$" ;
cin >> rOrM;
cout << "Enter your monthly phone payment: USD$";
cin >> phoneBill;
cout << "Enter your monthly utility payment: USD$";
cin >> utilities;
cout << "Enter your monthly cable payment: USD$";
cin >> cable;
total = (rOrM + phoneBill + utilities + cable);
cout << endl;
cout << setprecision(2) << fixed;
cout << "The monthly cost of these expenses is: USD$" << total << endl;
total = total * 12;
cout << "The annual cost of these expenses is: USD$" << total << endl;
system("pause");
return (0);
}