A Cable Company has hired you to write a C++ program that calculates the monthly bill for their customers. It must meet the following specifications:
CODE :
#include <iostream>
using namespace std;
int main()
{
string name;
int bc,pc;
cout<<"Hello there!"<<endl;
cout<<"Please enter your name : "<<endl;
cin>>name;
cout<<"Enter the number of basic channel packages :
"<<endl;
cin>>bc;
cout<<"Enter the number of premium channel packages :
"<<endl;
cin>>pc;
float cost = 75;
if(bc>3){
cost = cost+(bc-3)*12;
}
cost = cost + pc*15;
cost = cost*1.0235;
cout<<name<<", your bill for the month is :
"<<cost;
return 0;
}
Get Answers For Free
Most questions answered within 1 hours.