Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package lessons;
- public class Discount
- {
- // write a program that calculates the sale price
- //of an 59$ item with 20% off
- public static void main(String[] args)
- {
- double disc, Drate = .20, ogPrice = 59.0 , SalePrice;
- disc = ogPrice * Drate;
- SalePrice = ogPrice - disc;
- System.out.println("sale price: $"+SalePrice);
- }
- //chem,bio,mathAF,mathCV,compSci,CompEng,
- }
Add Comment
Please, Sign In to add comment