Question
#include using namespace std; int main() { float money; float rate; float total; string name; cout < < calculator_savingMoney_MoyaCano.cpp - Ivan Moya Cano < <
#include
using namespace std;
int main()
{
float money;
float rate;
float total;
string name;
cout << "calculator_savingMoney_MoyaCano.cpp - Ivan Moya Cano" << endl;
cout << "-----------------------------------------------------------------------------" << endl;
cout << "Name of Bank Costurmer: "; // This gives me error all the time.
cin >>name;
cout << "Amount of money in saving account:";
cin >> money;
cout << "Interest rate: ";
cin >> rate;
cout << "-----------------------------------------------------------------------------" << endl;
total = money + money * rate / 100;
cout << "Total money at the end of year round: " << total << endl;
system("pause");
return 0;
}
When I try to use the "STRING" variable, I fail to do this program. What would be my mistake?
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started