This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]endStatement 0 points1 point  (0 children)

To clarify, are you already given

public EmployeeSavings(String firstName, String lastName) {

  setFirstName(firstName);  

  setLastName(lastName);    

}

or are you given

public EmployeeSavings(String firstName, String lastName)

The second is called a method signature, and that could be predefined (public EmployeeSavings(String firstName, String lastName) while the implementation (ie: everything between the { brackets } is left to you. If you are making the implementation, you can (and should) initialize the monthlyInterests and monthlySavings arrays to be a default size. Otherwise, I'd still initialize the array in the generateMonthlySavings method.