R22
Code No: R22A0507
MALLA REDDY COLLEGE OF ENGINEERING & TECHNOLOGY
(Autonomous Institution – UGC, Govt. of India)
II [Link] II Semester Supplementary Examinations, November 2024
Object Oriented Programming through Java
(CSE,IT,CS&IT,CSE-CS,CSE-AIML,CSE-DS,CSE-IOT & [Link]-AIML)
Roll No
Time: 3 hours Max. Marks: 60
Note: This question paper contains two parts A and B
Part A is compulsory which carries 10 marks and Answer all questions.
Part B Consists of 5 SECTIONS (One SECTION for each UNIT). Answer FIVE Questions,
Choosing ONE Question from each SECTION and each Question carries 10 marks.
***
PART-A ( 10 Marks) BCLL CO(s) Marks
(Write all answers of this part at one place)
1 A What is the property used to know the length of an L1 CO-I [1M]
array?
B Define this pointer in Java. L1 CO-I [1M]
C List different types of inheritance. L1 CO-II [1M]
D When do we use the implements keyword? L1 CO-II [1M]
E What is the benefit of handling exceptions? L2 CO-III [1M]
F What is inter-thread communication? L1 CO-III [1M]
G What is a file? L1 CO-IV [1M]
H Define collection class? L1 CO-IV [1M]
I Give examples of an event. L1 CO-V [1M]
J Write syntax to create a JLabel swing component. L1 CO-V [1M]
PART-B ( 50 Marks)
SECTION-I
2 Discuss operators in Java with suitable examples. L2 CO-I [10M]
OR
3 A Compare and contrast class and object with a suitable L2 CO-I [5M]
program.
B Develop a Java program to find the factorial of a given L3 CO-I [5M]
number using recursion.
SECTION-II
4 A Explain the usage of the final keyword with suitable L2 CO-II [5M]
examples.
B Discuss abstract class in Java in detail. L2 CO-II [5M]
OR
5 A Discuss interfaces in detail with suitable examples. L2 CO-II [5M]
B Create a package named 'company' that contains the L3 CO-II [5M]
Employee class representing employee details. Include
methods for setting and retrieving employee information
such as name, ID, and salary. Then, showcase the
Page 1 of 2
process of importing this package into another Java class
and demonstrate the utilization of the Employee
functionalities.
SECTION-III
6 Discuss the different keywords of exception handling in L2 CO-III [10M]
Java in detail with suitable examples.
OR
7 A Explain the life cycle of a thread with a neat diagram. L2 CO-III [5M]
B Write a Java program to demonstrate thread priorities. L3 CO-III [5M]
SECTION-IV
8 A Write a Java program to demonstrate ArrayList. L3 CO-IV [5M]
B Discuss file management using File class. L2 CO-IV [5M]
OR
9 Discuss the different types of JDBC drivers, including L2 CO-IV [10M]
the advantages and disadvantages of each type,
accompanied by clear diagrams.
SECTION-V
10 A Briefly discuss AWT class hierarchy with a neat L2 CO-V [5M]
diagram.
B Explain the need for a layout manager in Java. Write a L3 CO-V [5M]
program to demonstrate the use of a layout manager.
OR
11 A Discuss Adapter classes and it’s role in detail. L2 CO-V [4M]
B Develop a Java swing application to handle mouse L3 CO-V [6M]
events.
***
Page 2 of 2