[SOLVED] This code isnt working and I don't know why, this code is for the total salaries practice in java
public class Program { public static void main(String[] args) { Worker worker1 = new Worker(); worker1.setName("James"); worker1.setSalary(200000); Worker worker2 = new Worker(); worker2.setName("Tom"); worker2.setSalary(150000); System.out.println(CalculateTotalSalary(worker1.getSalary(),worker2.getSalary())); } //complete the function to calculate the total salary static int CalculateTotalSalary(int sal1, int sal2) { int total=sal1+sal2; return total; } } class Worker{ private String name; private int salary; public String getName() { return name; } public String setName(String newName) { this.name=newName; } public int getSalary() { return salary; } public int setSalary(int newSalary) { this.salary=newSalary; } }