Mobile Service ProviderModify the program in Problem 5 so that it also displays how much package A customers would save if they purchased package B or C, and how much money Package B customers would save if they purchases Package C. If there would be no savings, no message should be printed. calculate the cost of all plans (A, B, and C) based on the number of minutes the user-entered. Then based on the plan user chose, compare, and calc. the difference among the plans.    this one has some error

Programming with Microsoft Visual Basic 2017
8th Edition
ISBN:9781337102124
Author:Diane Zak
Publisher:Diane Zak
Chapter6: Sub And Function Procedures
Section: Chapter Questions
Problem 2MQ2
icon
Related questions
Question
100%

C++ 

Mobile Service ProviderModify the program in Problem 5 so that it also displays how much package A customers would save if they purchased package B or C, and how much money Package B customers would save if they purchases Package C. If there would be no savings, no message should be printed.

calculate the cost of all plans (A, B, and C) based on the number of minutes the user-entered. Then based on the plan user chose, compare, and calc. the difference among the plans. 

 
this one has some error
#include <iostream>
using namespace std;
int main()
//variable declaration
char package;
int minutes;
float monthlyBill
e, monthlyBillA = 0, monthlyBillB = 0, monthlyBillC = 0;
%3D
//get user input
cout<<"Which package the customer has purchased(A, B, C): ";
cin>>package;
cout<<"How many minutes were used: ";
cin>>minutes;
monthlyBillA
if(minutes>450)
= 39.99;
monthlyBillA = monthlyBillA + 0.45 *
(minutes
450);
monthlyBillB
if(minutes>900)
monthlyBillB = monthlyBillB + 0.40 *
= 59.99;
(minutes
- 900);
monthlyBillC
= 69.99;
//calculate the monthly bill on the basis of selected package
if(package
{
if(monthlyBillA>monthlyBillB)
cout<<endl<<"The package B customer would save $"<<monthlyBillA-monthlyBillB;
if(monthlyBillA>monthlyBillC)
cout<<end1<<"The package C customer would save $"<<monthlyBillA-monthlyBillc;
}
'A')
==
Transcribed Image Text:#include <iostream> using namespace std; int main() //variable declaration char package; int minutes; float monthlyBill e, monthlyBillA = 0, monthlyBillB = 0, monthlyBillC = 0; %3D //get user input cout<<"Which package the customer has purchased(A, B, C): "; cin>>package; cout<<"How many minutes were used: "; cin>>minutes; monthlyBillA if(minutes>450) = 39.99; monthlyBillA = monthlyBillA + 0.45 * (minutes 450); monthlyBillB if(minutes>900) monthlyBillB = monthlyBillB + 0.40 * = 59.99; (minutes - 900); monthlyBillC = 69.99; //calculate the monthly bill on the basis of selected package if(package { if(monthlyBillA>monthlyBillB) cout<<endl<<"The package B customer would save $"<<monthlyBillA-monthlyBillB; if(monthlyBillA>monthlyBillC) cout<<end1<<"The package C customer would save $"<<monthlyBillA-monthlyBillc; } 'A') ==
'B')
if(package
{
if(monthlyBillB>monthlyBillC)
cout<<endl<<"The package C customer would save $"<<monthlyBillB-monthlyBillc;
}
//display result
if(package
cout<<endl<<endl<<"The total amount due = $"<<monthlyBil1A;
else if(package
==
'A')
==
'B')
==
cout<<end1<<end1<<"The total amount due =
$"<<monthlyBillB;
else if(package
cout<<endl<<endl<<"The total amount due =
==
(,ɔ.
$"<<monthlyBillc;
return 0;
}
Transcribed Image Text:'B') if(package { if(monthlyBillB>monthlyBillC) cout<<endl<<"The package C customer would save $"<<monthlyBillB-monthlyBillc; } //display result if(package cout<<endl<<endl<<"The total amount due = $"<<monthlyBil1A; else if(package == 'A') == 'B') == cout<<end1<<end1<<"The total amount due = $"<<monthlyBillB; else if(package cout<<endl<<endl<<"The total amount due = == (,ɔ. $"<<monthlyBillc; return 0; }
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 3 images

Blurred answer
Knowledge Booster
Mathematical functions
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage