Question: 16. Write the following lines of java for a sales program. You can assume the Scanner input has been declared earlier as well as all
16. Write the following lines of java for a sales program. You can assume the Scanner input has been declared earlier as well as all of the initial lines of code that begin our program. Only write the code described within the comments // Declare three decimal variables named price, discount, and discount Price // Ask and Get the price from the user If the price is less than 100, then the discount is 10% of price, otherwise the discount is 14% of price. //Evaluate the discount here. //Calculate the discounted price from price minus the discount. //Tell the user what the discounted price is for the item
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
