Advertisement
mcnealk

#13

Oct 2nd, 2014
206
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. /**
  2. * Write a description of class ExerciseThirteen here.
  3. * Kailey McNeal
  4. * 10-2-14
  5. * #13 p 191
  6. */
  7. public class ExerciseThirteen
  8. {
  9. public static void main (String []args)
  10. {
  11. pay(5.50,6);
  12. }
  13. public static void pay (double hours, double pay)
  14. {
  15. if (hours<8.00)
  16. {
  17. pay=hours * pay;
  18. System.out.print(pay);
  19. }
  20. else
  21. {
  22. double overhours=(hours-8.00);
  23. pay=(overhours*(pay*1.5)) + (hours*pay);
  24. System.out.print(pay);
  25. }
  26. }
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement