Question: Gaddis Pseudocode Module main ( ) / / Declare variables. Declare Integer cdPurchased / / Ask the user to input the number of CDs they

Gaddis Pseudocode Module main()// Declare variables. Declare Integer cdPurchased // Ask the user to input the number of CDs they wish to purchase, then call in the cdCosts module to calculate discoutns and final price. Display "Please enter the number of CDs you'd wish to purchase." Input cdPurchased Call cdCosts(cdPurchased) End Module Module cdCosts (Integer cdPurchased)// Declare variables for calculating discounts. Declare Integer originalPrice, finalPrice, discount // Display an error message if user inputs a number that is less than zero, if more than zero then the program continues to calculate discounts If cdPurchased >0 Then // IF statement for when the number of CDs purchased is less than ten, if more than 10, then the program continues down the list till it goes above 40 where the discount hits a limit of 25% off. If cdPurchased <10 Then Set cdPurchased = cdPurchased *15 Display "Your total cost is: ", cdPurchased Else If cdPurchased <=20 Then

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!