How will you create the class for the following scenario?

Employees under one employee?

Answers were Sorted based on User's Feedback



How will you create the class for the following scenario? Employees under one employee? ..

Answer / satya

Employee class

SubEmployee extends Employee

Is This Answer Correct ?    6 Yes 1 No

How will you create the class for the following scenario? Employees under one employee? ..

Answer / jagdish

class Employee {
Integer empCode;
String firstName;
String lastName;
List<Employee> subEmployees;
}

Is This Answer Correct ?    4 Yes 1 No

Post New Answer

More Core Java Interview Questions

What are the benefits of operations?

0 Answers  


Is there a sort function in java?

0 Answers  


Can we assign integer value to char in java?

0 Answers  


What is meant by class loader and how many types are there?

2 Answers   Apple,


write a program to create an arraylist and listeterator.and value should be enter through keyboard.

1 Answers   Axcend,






what is the replacement method of stop() of thread

8 Answers   IBM, TCS,


What are data structures in java?

0 Answers  


Can you write a java class that could be used both as an applet as well as an application?

0 Answers  


What is the purpose of having the concept of overloading?

7 Answers   Ness Technologies,


Why hashmap is used in java?

0 Answers  


What is the difference between the paint() and repaint() methods?

0 Answers  


Explain serialization and deserialization in java?

0 Answers  


Categories