0% found this document useful (0 votes)
2 views2 pages

Java Question Bank

The document is a comprehensive Java question bank covering five course objectives (CO1-CO5). It includes questions on various Java topics such as packages, access modifiers, inheritance, exception handling, JavaBeans, JDBC, GUI development with Swing, socket programming, applet lifecycle, and servlets. Each course objective contains multiple questions aimed at assessing understanding and practical application of Java concepts.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views2 pages

Java Question Bank

The document is a comprehensive Java question bank covering five course objectives (CO1-CO5). It includes questions on various Java topics such as packages, access modifiers, inheritance, exception handling, JavaBeans, JDBC, GUI development with Swing, socket programming, applet lifecycle, and servlets. Each course objective contains multiple questions aimed at assessing understanding and practical application of Java concepts.
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Java Question Bank

CO1-CO5
CO1:
1. Describe how packages are created and used in Java to organize programs.
2. Write a simple Java program to demonstrate the use of access modifiers in classes.
3. Describe the execution flow of a Java program and explain the roles of JVM, JRE,
and JDK.
4. Illustrate how inheritance works in Java and implement method overriding using a
simple example.
5. Explain the concept of exception handling and demonstrate the use of try catch finally
with a program.
6. Differentiate between compile-time and runtime errors with suitable examples.
7. Demonstrate how multithreading is implemented in Java using Thread class or
Runnable interface.
8. Explain the lifecycle of a thread and illustrate it using a simple diagram or example.

CO2:
1. Describe how custom events are created and handled in JavaBeans.
2. Explain the concept of JavaBeans and describe different types of properties with an
example.
3. Develop a JavaBean class and demonstrate how getter and setter methods are used.
4. Describe the event delegation model and explain the role of event source, event
object, and listener.
5. Write a program to demonstrate event handling using action listeners.
6. Explain the features of Java Foundation Classes (JFC) and their importance in GUI
development.
7. Explain different types of layout managers used in GUI applications.
8. Illustrate how BeanBox is used

CO3:
1. Explain how connection pooling improves database performance in JDBC.
2. Differentiate between Statement and PreparedStatement with suitable examples.
3. Explain how transaction management works in JDBC and why it is important for data
consistency.
4. Write a Java program to connect to a database and retrieve records from a table.
5. Describe the architecture of JDBC and explain how different components interact.
6. Demonstrate how CRUD operations are performed using JDBC with a simple
example.
7. Describe the mapping between SQL data types and Java data types.
8. Write a Java program to create a table and insert records into it using JDBC.
CO4:
1. Demonstrate how text fields, password fields, and text areas are used in Swing.
2. Explain the working of dialog boxes and their types in GUI applications
3. Explain the MVC design pattern and describe how it is applied in Swing applications.
4. Develop a simple GUI application using JFrame, JLabel, and JButton.
5. Compare different layout managers such as BorderLayout and GridLayout with
examples.
6. Write a program to create a form using Swing components and handle user input.
7. Describe the role of menus and toolbars in GUI design with an example.
8. Explain how event handling is integrated with Swing components in GUI
applications.

CO5:
1. Explain the concept of socket programming and demonstrate client-server
communication.
2. Describe the lifecycle of an applet and explain each stage with a diagram or example.
3. Write a simple applet program and demonstrate how it is embedded in an HTML
page.
4. Describe the working of URLs in Java and how they are used in networking.
5. Explain Enterprise JavaBeans (EJB) and differentiate between session, entity, and
message-driven beans.
6. Write a program to demonstrate basic socket communication between client and
server.
7. Explain the role of servlets in web-based applications and their advantages.
8. Describe how remote method invocation (RMI) works in distributed Java
applications.

You might also like