Advertisement
Vexus

Exercise 3.8

Oct 7th, 2014
158
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. package stuff;
  2.  
  3. public class Employee {
  4.  
  5. public static void main(String[] args) {
  6. Employee diddle = new Employee();
  7. diddle.raiseSalary(salary);
  8. diddle.getSalary(salary);
  9. System.out.println(salary);
  10.  
  11.  
  12. }
  13. public static double salary;
  14. public double amount;
  15.  
  16. public void salary(double salary) {
  17. this.salary = 5000;
  18. }
  19. public double getSalary(double salary) {
  20. return this.salary;
  21.  
  22. }
  23. public void raiseSalary(double salary) {
  24. this.salary = amount *.10;
  25. }
  26.  
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement