Guest User

Untitled

a guest
Jun 18th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. /* Lab 2 number 8 */
  2.  
  3.  
  4. import java.util.Scanner;
  5.  
  6. public class Lab28
  7. {
  8.  
  9. public static void main(String[] args)
  10. {
  11. String stritem;
  12.  
  13. double dblstatetax=.04;
  14. double dblcountytax=.02;
  15. double dbltotaltax;
  16. double dbltotal;
  17. double dblNumber1;
  18.  
  19. Scanner objKeyboard = new Scanner(System.in);
  20.  
  21. System.out.print("Enter the amount of the purchase: ");
  22. dbltotal = objKeyboard.nextInt ();
  23.  
  24. dblNumber1 = dbltotal * dblstatetax;
  25.  
  26.  
  27. System.out.print(dblNumber1);
  28.  
  29. System.out.print("\nState sales tax = .04" );
  30. System.out.print("\nCounty sales tax = .02" );
  31. System.out.print("\nTotal sales tax = ");
  32. System.out.print("\nThe total of the sale: " );
  33.  
  34. }
  35. }
Add Comment
Please, Sign In to add comment