How will you create the class for the following scenario?
Employees under one employee?
Answer Posted / jagdish
class Employee {
Integer empCode;
String firstName;
String lastName;
List<Employee> subEmployees;
}
Is This Answer Correct ? | 4 Yes | 1 No |
Post New Answer View All Answers
Why do we need array in java?
What is the purpose of declaring a variable as final?
Why do we need strings in java?
What is a static class in java?
What is quick sort in java?
What does java se mean?
Explain java heap space and garbage collection?
What is meant by method overriding?
Why string is not thread safe?
What is a Presistent Object?
What is java’s garbage collected heap?
Which class cannot be a subclass in java?
What is the purpose of skeleton and stub?
Can we write a class without main method in java?
What are methods of a class?