Question: JAVA SCRIPT Write an Employee class with following properties: * name * address * salary 1. All member fields must be private. Provide getter and
JAVA SCRIPT
Write an Employee class with following properties: * name * address * salary 1. All member fields must be private. Provide getter and setter methods to access and modify each of the member fields.
2. Override the toString method to return the values of all the member fields. 3. In your main method create two instance of the Employee class.
4. Print the content of the Employee instances using System.out.println and the toString method
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
