I'm getting an error in my Java code but I can't see whats wrong with it. Help?

前端 未结 5 1766
轻奢々
轻奢々 2021-01-23 14:20

The error i\'m getting is in the fillPayroll() method in the while loop where it says payroll.add(employee). The error says I can\'t invoke add() on an array type Person but th

5条回答
  •  难免孤独
    2021-01-23 14:28

    payroll is an array. You are invoking method on an array. This is not possible.

提交回复
热议问题