Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Pragram Description Write a method that presauts the usar with the choices to enter their mambarshy type. The method must ask the user to enter
Pragram Description
Write a method that presauts the usar with the choices to enter their mambarshy type. The method must ask the user to enter a selection of one of thres
types of membership Fundamental or Pramier Inpus Validation: The program must only accapt one of the valid types of memberships. If the user's
return a validatsd mambership typa. Ses the Sample Run Videss.
Write a method that accepts one argunent: the menbership type. The mathod must raturn the base coct of the mambarship. The base cost of the
Write a method that accepts ous argament: the membership type. The mathod must raturn the maximum fras flute lassons that are inclodad in the
Write a method that accepts ons argument: the membership type. The mathod must raturn the hourly rate for flute lassoes for asch membership. Tha
borrly rate fot flute lessons in each mambarshy csn be dotermined using the information balow:
Write a method that gets the input of the muber of hours a user desires to bock for a flute lasson. When callad, the method mast accapt the folloring
srguments: the nemberskip type, the remsining free sessions in the membership, and the hourly rate for the mambarship. The method has to
for a lessoe. The method mast return the ralidated number of hours entersd. See the Sample Run Videos.
Write a method that diplays informstion about the customer's mambership. When callad, this method must accept the following arguments: the
menbership type, the number of free sesions included in the membership, the hourly rate for flute lessons, and the base cost of the
membership. This mothod must use the rgumests to display the information about tha mambarship wase calls. Sos the Sample Run Videos.
Write a method that displays a final imvice for a castomar's membership along with included flute lasson fass. When callod, this mothod must accapt the
following argumant: membership base cost, the total number of lessous booked, the total hours of flute lessom, and the total lesson charges. This
machod mast use the srgments to dsplay the imvice information as wall as the calculatad total chargas base coct of mambarship the totsl flute lesson
chargas See the Sample Run Videos.
B Write a method that caleulatse the price of a simgle flute lassoe. This machod nast accept the following argumans: the remaining free lessons in the
membership, the hourly rate for the membership, and the number of hours booked for the flute lesson. The mothod must ratum the calculated
price of the hasson. Note: the calculation is not providad. You must create the calculation. Fint you will also asod to accom for the incleded fros
sascions in the mambarship in yorr calculations
When the program rus, it mast do the folloring operstions by calling mathods from msin:
Call the appropriate method to get the ingut of the mambarkip typa, them set the following: the included frae lassom, mambarshy base cost,
wal the hourly rate for a sessiou by calling the approprists mathods.
Call the nppropriate method to display information about tha usar's Fhate Lesson Mambarship
Use a loop to ask the usar if thay would like to enter information to book a flute lesson:
If so call the gypopriate mathod to gat the ingot of the hous for the sassion
Then, calculate the flute losson cost using the appropriate method.
Then, contimuously raquast the input of more flute lassows and kesp processing matl the usar chooses to stop.
If not, stop the loop and displsy the invoice for the membership and finte lessons
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