KEMBAR78
Java QB | PDF | Method (Computer Programming) | Inheritance (Object Oriented Programming)
0% found this document useful (0 votes)
2 views8 pages

Java QB

The document is a question bank for the OOP Through Java course at St. Peter’s Engineering College for the academic year 2025-26. It includes questions categorized by Bloom's taxonomy across various units covering topics such as abstract classes, inheritance, exception handling, and event handling in Java. Each question is assigned a mark value and a corresponding Bloom's level to assess students' understanding and application of the concepts.

Uploaded by

M Vinitha
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 views8 pages

Java QB

The document is a question bank for the OOP Through Java course at St. Peter’s Engineering College for the academic year 2025-26. It includes questions categorized by Bloom's taxonomy across various units covering topics such as abstract classes, inheritance, exception handling, and event handling in Java. Each question is assigned a mark value and a corresponding Bloom's level to assess students' understanding and application of the concepts.

Uploaded by

M Vinitha
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
You are on page 1/ 8

Department of Computer Science and Engineering – AIML

AS22-05PC07 – OOP Through Java Question Bank

St. Peter’s Engineering College (Autonomous) Dept. : CSE - DS


Dullapally (P), Medchal, Hyderabad – 500100. Academic Year
QUESTION BANK 2025-26
Subject Code : AS22-05PC07 Subject : OOP Through Java
Class/Section : B. Tech. Year : II Semester : I

BLOOMS LEVEL
Remember L1 Understand L2 Apply L3
Analyze L4 Evaluate L5 Create L6
*****
UNIT-I

Q. No Question (s) Marks BL CO


PART-A
1 What is abstract class? Give example. 1M Understand C215.1
Explain the use of ‘for’ statement in Java with an Understand C215.1
2 1M
example.
3 Explain the purpose of this keyword in Java. 1M Understand C215.1
4 Why is Java called platform-independent? 1M Understand C215.1
Apply if-else control structure to check if a number is C215.1
5 1M Apply
positive or negative.
6 What is variable? 1M Remember C215.1
7 Differentiate between class and object. 1M Understand C215.1
Why is abstraction important in object-oriented C215.1
8 1M Analyze
programming?
9 Explain the purpose of this keyword in Java. 1M Understand C215.1
Write a simple Java program to print the sum of two 1M C215.1
10 Apply
numbers.
PART- B
1 What are the responsibilities of an agent? 5M Remember C215.1
What is the purpose of constructor in Java 5M C215.1
2 Understand
programming?
How does polymorphism promote extensibility? 5M C215.1
3 Analyze
Explain with example.
What are the primitive data types available in Java? 5M C215.1
4 Remember
Explain.
Give the syntax of various control statements used in 5M Understand C215.1
5
Java programs and explain them.
What is polymorphism? Explain different types of 5M Understand C215.1
6
polymorphisms with examples.
What is method overloading? Explain with an 5M C215.1
7 Apply
example program.
Explain the important principles of Object-Oriented 5M Understand C215.1
8
Programming Paradigm.
9 Explain the importance of constructor. 5M Understand C215.1
10 What are Java buzzwords? Explain in detail. 5M Remember C215.1
Write a program to compute division by 2 without C215.1
11 10M Create
using any arithmetic operator.
Write a program to illustrate a copy constructor so 10M C215.1
12 that a string may be duplicated into another variable Apply
either by assignment or copying.
Explain the concept of dynamic binding with an 10M C215.1
13 Analyze
example program.
Develop a java program to display the following 10M Create C215.1
output.
1
14 12
123
1234
12345
Given two one dimensional arrays A and B which are 10M Create C215.1
sorted in ascending order. Write a program to merge
15
them into a single sorted array C that contains every
item from arrays A and B, in ascending order.
Explain various access modifiers (private, public, 10M Understand C215.1
16
protected and default) used in JAVA.
Explain the following with example 10M Understand C215.1
a) this keyword.
17
b) garbage collection.
c) Constructor
Explain Data abstraction encapsulation and 10M Understand C215.1
18
inheritance with suitable example.
Discuss the drawbacks of procedural languages and 10M C215.1
19 explain the need of object-oriented programming with Analyze
suitable program.
Illustrate constructor overloading concept with an 10M C215.1
20 Apply
example.
UNIT-II

Q. No Question (s) Marks BL CO


PART-A
Mention two differences between method overloading
1 1M Understand C215.2
and overriding.
2 Define a Package? What is its use in java? Explain. 1M Understand C215.2
3 Contrast between abstract class and interface. 1M Analyze C215.2
4 Differentiate class, abstract class and interface. 1M Analyze C215.2
5 How to create and use a package in Java program? 1M Apply C215.2
6 What is an abstract class? 1M Remember C215.2
What is the significance of the CLASSPATH Understand C215.2
7 1M
environment variable in creating/using a package?
8 What is inheritance in Java? 1M Understand C215.2
9 Define a Package? 1M Remember C215.2
10 Write syntax to implement an interface in Java. 1M Apply C215.2
PART- B
What is inheritance and how does it help to create C215.2
1 5M Understand
new classes quickly.
What is an interface? What are the similarities 5M C215.2
2 Understand
between interfaces and classes?
How can you extend one interface by the other 5M Apply C215.2
3
interface? Discuss.
Discuss how to define and import a package? Explain 5M Apply C215.2
4
with an example.
Discuss the variables in interfaces and extending 5M Understand C215.2
5
interfaces.
Discuss how java handles overridden methods. In 5M
short, how base class member functions can be
6 Analyze C215.2
invoked in a derived class if the derived class also has
a member function with the same name.
Explain with an example how multiple inheritance is 5M C215.2
7 Apply
achieved in Java.
Write a program to demonstrate hierarchical and 5M C215.2
8 Create
multiple inheritance using interfaces
9 Discuss about CLASSPATH environment variables. 5M Understand C215.2

10 Demonstrate with an example method overriding. 5M Apply C215.2

Explain nested interfaces with an example JAVA Apply C215.2


11 10M
program.
Explain the various levels of protection provided to 10M C215.2
12 the variables or methods within classes, subclasses, Understand
and packages in java.
What are the benefits of inheritance? Explain the 10M Analyze C215.2
13 various forms of inheritance with suitable code
segments.
Explain how JAVA implements run-time 10M Apply C215.2
14
polymorphism. Give an example.
What is polymorphism? Differentiate between 10M C215.2
15 compile time and runtime polymorphism with the Analyze
help of complete java program.
Discuss basic in-built packages in java and their uses 10M C215.2
16 in application development in brief. Which package is Understand
the default package?
Justify the concept of variables in interfaces and 10M C215.2
17 Evaluate
extending interfaces with example code
Design an interface called Shape with methods draw() 10M Create C215.2
and getArea(). Further design two classes called
Circle and Rectangle that implements Shape to
18
compute area of respective shapes. Use appropriate
getter and setter methods. Write a java program for
the same.
Write a program which has an abstract class Solid and 10M Create C215.2
19 implements Cylinder, Cone and Sphere by inheriting
from solid to find surface area and volume.
What is Multilevel Inheritance? Write a program to 10M C215.2
20 Apply
demonstrate multilevel inheritance.

UNIT-III

Q. No Question (s) Marks BL CO


PART-A
1 Define exception in Java. 1M Remember C215.3
What is the purpose of the finally block in exception C215.3
2 1M Remember
handling?
3 What is autoboxing in Java? 1M Remember C215.3
4 Which method is used to start a thread? 1M Remember C215.3
5 Explain the role of the throws keyword. 1M Understand C215.3
6 What is the use of annotations in Java? 1M Understand C215.3
7 Define multitasking. 1M Remember C215.4
8 Write the complete life cycle of a thread 1M Remember C215.4
Which method would you use to pause a thread for 2 C215.4
9 1M Apply
seconds?
Which thread method would you override in a custom C215.4
10 1M Apply
thread class?
PART- B
What are advantages of using Exception handling C215.3
1 5M Understand
mechanism in a program?
Write a java program that demonstrates how certain 5M C215.3
2 Apply
exception types are not allowed to be thrown.
Explain the concept of java built in exceptions with an 5M C215.3
3 Understand
example.
4 Write a short note on thread life cycle. 5M Understand C215.3
5 Discuss about thread based multitasking. 5M Understand C215.3
Explain checked exceptions and unchecked 5M C215.4
6 Understand
exceptions with example.
7 Write a java program to create multiple threads. 5M Apply C215.4
8 Discuss the nested try Statements. 5M Understand C215.4
9 Write the syntax of nested try and catch blocks 5M Remember C215.4
Describe producer-consumer pattern using inter- 5M C215.4
10 Analyze
thread communication
Write a program to illustrate user defined exception C215.3
that checks the internal and external marks if the
internal marks are greater than 40 it raise the
11 10M Create
exception “internal marks are exceed”, if the external
marks are greater than 60 exception is raised and
display the message the “external marks are exceed.”
How to handle multiple catch blocks for a nested try 10M C215.3
12 Apply
block? Explain with an example.
Write short notes on the following with examples: 10M C215.3
a) Autoboxing
13 b) Enumerations Understand
c) Annotations
d) Generics
Explain the multiple catch blocks with example 10M C215.3
14 Apply
program
Discuss the role of synchronization in multithreaded 10M C215.3
15 programs. Illustrate how to achieve thread Analyze
synchronization in Java with example programs.
Write java program to create the user defined 10M C215.4
16 Create
exception.
Explain Multithreading. In how many ways java 10M C215.4
17 implements multithreading? Explain at least one of Apply
these ways with appropriate example.
Write a program that demonstrate the priority setting 10M C215.4
18 Apply
in threads.
Write a program to create four threads using Runnable 10M C215.4
19 Apply
interface.
What are the different ways that are possible to create 10M C215.4
20 multiple threaded programs in java? Discuss the Analyze
differences between them.

UNIT-IV

Q. No Question (s) Marks BL CO


PART-A
1 What is the purpose of an Event Listener? 1M Understand C215.5
2 Identify the class used to handle mouse events. 1M Remember C215.5
Mention one difference between Checkbox and C215.5
3 1M Understand
CheckboxGroup.
Which layout manager displays components in a C215.5
4 1M Remember
single line?
Which method is invoked when a button is clicked in C215.5
5 1M Remember
AWT?
6 What is the use of ScrollPane in Java AWT? 1M Understand C215.5
Choose a suitable layout for components arranged in C215.5
7 1M Apply
rows and columns.
Which AWT component is used to display a static C215.5
8 1M Remember
text?
Which listener interface handles window closing 1M C215.5
9 Remember
events?
10 Explain checkbox groups 1M Understand C215.5
PART- B
Explain procedure to handle mouse events in Java C215.5
1 with an example program. 5M Apply

Explain the process of event handling through 5M C215.5


2 Understand
delegation model.
What is an adapter class? Demonstrate its role in 5M C215.5
3 Apply
event handling.
4 Explain AWT class hierarchy. 5M Understand C215.5
5 List and explain the limitations of AWT. 5M Understand C215.5
What is the role of event listeners in event handling? 5M C215.5
6 Understand
List the Java event listeners.
7 Illustrate the use of Grid Bag layout. 5M Apply C215.5
Discuss the advantages and disadvantages of using 5M C215.5
8 Analyze
adapter classes
9 Explain about “Button” component. 5M Understand C215.5
What is a Layout manager? Explain different types of 5M C215.5
10 Understand
Layout managers.
Write a java program to design a scientific calculator C215.5
11 10M Create
using AWT.
Describe in detail about the various event listener 10M C215.5
12 Understand
interfaces.
13 Discuss various AWT containers with examples. 10M Apply C215.5
Demonstrates the different types of Event Listeners 10M C215.5
14 Apply
supported by java.
15 Discuss in detail 5 types of Layout Managers. 10M Understand C215.5
Explain the complete event handling mechanism in Java, 10M C215.5
16 covering event sources, listeners, event classes, and their Evaluate
interactions in detail.
Write a program in awt to design the registration 10M C215.5
17 Create
form.
How the events of the mouse and keyboard can be 10M C215.5
18 Apply
handled? Explain with an example.
What is Layout manager? Discuss different types of 10M C215.5
19 Apply
layout managers used in JAVA with demonstration.
a) Explain various event adapter classes in awt and 10M C215.5
also give their syntaxes in java.
20 Apply
b) Write a program in awt to design the registration
form.

UNIT-V

Q. No Question (s) Marks BL CO


PART-A
1 What is an applet in Java? 1M Remember C215.6
2 Write the full form of MVC in Swing architecture. 1M Remember C215.6
3 What is the use of the JLabel component in Swing? 1M Remember C215.6
What is the class used for creating scrollable views in Remember C215.6
4 1M
Swing?
Explain why applets cannot run independently like Understand C215.6
5 1M
applications.
Describe the role of the start() method in the applet Understand C215.6
6 1M
life cycle.
Name the container used to hold multiple tabs in C215.6
7 1M Remember
Swing.
Select the correct Swing class to display an image as C215.6
8 1M Apply
an icon.
What component would you use to create a simple C215.6
9 1M Apply
text input field in Swing?
10 Name any two types of applets. 1M Remember C215.6
PART- B
Write an applet program that will take an input from C215.6
1 5M Create
the user to calculate the sum of two integers.
2 Explain how the parameters are passing to an applet. 5M Understand C215.6
Discuss about different applet display methods in 5M C215.6
3 Understand
brief.
Create a simple applet to display a smiley picture 5M C215.6
4 Create
using Graphics class methods.
Explain the concept of MVC architecture in Java 5M C215.6
5 Understand
Swing.
Develop a Java Swing GUI using JFrame to take 5M C215.6
6 Create
student details and display them on the same frame.
Develop a simple applet that accepts two numbers 5M C215.6
7 Create
from the user and displays their sum.
Analyze the differences between heavyweight and 5M C215.6
8 Analyze
lightweight components with suitable examples.
Assess the effectiveness of using tabbed panes in 5M C215.6
9 Evaluate
organizing content within a single window.
Discuss how layout managers affect the design and 5M C215.6
10 Analyze
responsiveness of a Swing GUI.
List the major differences between applets and C215.6
11 10M Remember
applications in Java.
Explain the concept of Model-View-Controller 10M C215.6
12 Understand
(MVC) architecture in the context of Swing.
Discuss the significance of JComponent in the Swing 10M C215.6
13 Understand
hierarchy.
Write a Java program using an applet to display a 10M C215.6
14 Apply
simple message and demonstrate applet methods.
a) What is an applet? Explain the life cycle of Applet 10M C215.6
with a neat sketch.
15 Understand
b) Write the applets to draw the Cube and Cylinder
shapes.
Describe various types of applets and their usage in 10M C215.6
16 Create
Java programs
Design an applet that accepts two numbers from the 10M C215.6
17 user using TextFields and displays their sum when a Understand
button is clicked.
Create a Swing application using JFrame that contains 10M C215.6
18 Labels, TextFields, and a JButton to display a greeting Create
message.
19 Explain MVC Architecture. 10M Create C215.6
Write a program to display the month names by JList 10M C215.6
20 Understand
and display the Days by JComboBox

You might also like