OOPCG Oral Exam Q&A; – SE SPPU (2024 Pattern)
Detailed Answers + Case Studies
Unit 1: Introduction to OOP Concepts and Control Structures
1. What is Object-Oriented Programming? → OOP is a programming paradigm that organizes
software around objects rather than actions. Each object represents a real-world entity and has
attributes (data) and behavior (methods). This helps improve code reusability, modularity, and
scalability.
2. What are the main features of OOP? → The main features are Encapsulation (data hiding),
Inheritance (code reuse), Polymorphism (one name, many forms), and Abstraction (showing only
essential details). These make the program easier to maintain and extend.
3. What is a class and object? → A class is a blueprint that defines properties and behaviors, while
an object is an instance of a class. For example, ‘Car’ is a class, and ‘myCar’ is an object created
from it.
4. What is a constructor? → A constructor is a special method with the same name as the class,
automatically called when an object is created. It is mainly used to initialize variables.
5. Explain control structures in Java. → Control structures direct the flow of program execution.
They include conditional statements (if, if-else, switch) and looping statements (for, while, do-while)
for repetitive tasks.
6. What is JVM? → The Java Virtual Machine executes compiled bytecode and makes Java
platform-independent. It manages memory and provides security.
7. Explain difference between procedural and OOP. → Procedural programming focuses on
functions, while OOP focuses on data and objects. OOP promotes modularity and reuse, making
code easier to manage.
Unit 2: Classes, Objects, and Arrays
1. What are class members? → Members include variables (attributes) and methods (functions)
defined within a class. They represent the state and behavior of objects.
2. What are access specifiers? → They define how members of a class are accessed. public allows
access from anywhere, private restricts access to within the class, and protected allows access
within subclasses.
3. Explain static keyword. → The static keyword means a variable or method belongs to the class
rather than any object. For example, static int count is shared by all objects of that class.
4. What is an array in Java? → An array stores multiple values of the same data type. Arrays can
be single or multi-dimensional and are useful for handling large data sets efficiently.
5. What is an array of objects? → It stores multiple object references in one array. For example,
Student s[] = new Student[5]; creates an array of five Student objects.
6. What are command-line arguments? → Inputs passed to the main() method when a Java
program runs. They allow users to provide runtime input without hardcoding values.
Unit 3: Inheritance, Polymorphism, Exception Handling, and
Multithreading
1. Define inheritance. → It is a mechanism that allows one class (child) to use fields and methods of
another class (parent). It promotes code reuse and helps in hierarchical classification.
2. What are the types of inheritance in Java? → Single, Multilevel, and Hierarchical. Java does not
support multiple inheritance with classes to avoid ambiguity.
3. What is method overriding? → It allows a subclass to redefine a method already defined in the
parent class. It supports runtime polymorphism.
4. Explain polymorphism. → Polymorphism means the same function name can perform different
tasks depending on the object calling it. It is achieved through method overloading and overriding.
5. What is an abstract class and interface? → An abstract class has abstract methods and cannot
be instantiated. An interface contains only abstract methods and constants, used to achieve
multiple inheritance.
6. What is exception handling? → It is a process of handling runtime errors using try, catch, throw,
throws, and finally blocks. It ensures program stability even when unexpected conditions occur.
7. What is multithreading? → It enables concurrent execution of multiple parts of a program.
Threads improve performance by utilizing CPU efficiently.
8. What are thread methods? → Common methods are start(), run(), sleep(), join(), and yield().
They control thread execution flow.
Unit 4: Graphics Primitives, Scan Conversion, Windowing and
Clipping
1. What is computer graphics? → It is the field of computer science that deals with creating, storing,
and manipulating visual content like images, animations, and shapes.
2. What is a pixel? → The smallest unit of a digital image. A combination of millions of pixels forms
a display image.
3. Explain DDA algorithm. → The Digital Differential Analyzer (DDA) algorithm calculates
intermediate points between the start and end of a line using floating-point arithmetic. It’s simple but
slower than Bresenham’s algorithm.
4. Explain Bresenham’s algorithm. → It uses integer arithmetic for line drawing, which makes it
faster. It selects the nearest pixel position to approximate a straight line.
5. What is polygon clipping? → It is the process of removing parts of a polygon outside a specified
boundary (window). The Sutherland–Hodgeman algorithm is used for this.
6. What is Cohen–Sutherland line clipping? → It uses region codes for endpoints to quickly decide if
a line is visible, invisible, or needs clipping.
7. What is viewport? → A rectangular area on the display device that shows the mapped portion of
the image after clipping and transformation.
Unit 5: 2D & 3D Transformations, Projections, and Case Studies
1. What are 2D transformations? → Operations such as translation, rotation, scaling, and shearing
that change an object’s position, orientation, or size in a two-dimensional plane.
2. Explain translation. → It shifts an object from one position to another by adding translation factors
(tx, ty) to its coordinates.
3. What is scaling? → It increases or decreases the size of an object using scaling factors (Sx, Sy).
It helps in resizing objects proportionally.
4. Explain rotation. → It rotates an object about an origin or a point by a specific angle θ. Rotation is
widely used in animations and modeling.
5. Explain 3D transformations. → They include translation, rotation, and scaling in 3D space. It
helps in representing and viewing 3D models from various angles.
6. What is projection? → It converts 3D objects into 2D views for display. Parallel projection
preserves the object's dimensions, while perspective projection shows depth.
7. Case Study – Banking System: The system uses OOP concepts like classes (Account),
inheritance (SavingsAccount, CurrentAccount), and encapsulation for secure data. Methods handle
deposits, withdrawals, and balance checks.
8. Case Study – Library Management System: Classes like Book, Member, and Library are used. It
demonstrates file handling, object arrays, and method overriding.
9. Case Study – 2D Transformation Visualization: Programs demonstrate scaling, rotation, and
translation of polygons, showing real-world use of transformation matrices in graphics applications.