Interview Tutorials

1. The output of System.out.println(5<<2) in Java

By: Nirmal : 2023-05-11

Description: In this case, 5 is represented in binary as 00000101. When we shift it left by two positions, we get 00010100, which is the binary representation of 20. Therefore, the output is 20


2. The output of System.out.println(5>>2) in Java

By: Nirmal : 2023-05-11

Description: In this case, 5 is represented in binary as 00000101. When we shift it right by two positions, we get 00000001, which is the binary representation of 1. Therefore, the output is 1


3. What is J2EE?

By: Karthik : 2012-06-16

Description: J2EE Stands for Java 2 Enterprise Edition. J2EE is an environment for developing and deploying enterprise applications. J2EE specification is defined by Sun Microsystems Inc. now acquired by Oracle.


4. What do you understand by a J2EE module?

By: Karthik : 2012-06-16

Description: A J2EE module is a software unit that consists of one or more J2EE components of the same container type along with one deployment descriptor of that type. J2EE specification defines four types of modules


5. Tell me something about J2EE component?

By: Karthik : 2012-06-16

Description: A J2EE module is a software unit that consists of one or more J2EE components of the same container type along with one deployment descriptor of that type. J2EE specification defines four types of modules


6. What are the contents of web module?

By: Karthik : 2012-06-16

Description: A J2EE module is a software unit that consists of one or more J2EE components of the same container type along with one deployment descriptor of that type. J2EE specification defines four types of modules


7. Differentiate between .ear, .jar and .war files.

By: Karthik : 2012-06-16

Description: Answer: These files are simply zipped file using java jar tool. These files are created for different purposes. Here is the description of these files:


8. What is the difference between Session Bean and Entity Bean?

By: Karthik : 2012-06-16

Description: Session Bean: Session is one of the EJBs and it represents a single client inside the Application Server. Stateless session is easy to develop and its efficient. As compare to entity beans session beans require few server resources.


9. Why J2EE is suitable for the development of distributed multi-tiered enterprise applications?

By: Karthik : 2012-06-16

Description: Answer: The J2EE platform consists of multi-tiered distributed application model. J2EE applications allows the developers to design and implement the business logic into components according to business requirement. J2EE architecture allows the development of multi-tired applications and the developed applications can be installed on different machines depending on the tier in the multi-tiered J2EE environment . The J2EE application parts are:


10. What do you understand by a container in J2EE?

By: Karthik : 2012-06-16

Description: Normally, thin-client multi-tiered applications are hard to write because they involve many lines of intricate code to handle transaction and state management, multithreading, resource pooling, and other complex low-level details. The component-based and platform-independent J2EE architecture makes J2EE applications easy to write because