Object-Oriented Analysis & Design (OOAD) MCQs with Answers
What is the primary goal of Object-Oriented Analysis and Design (OOAD)?
a) To develop software using procedural programming
b) To create a system based on objects and their interactions
c) To eliminate the need for testing
d) To focus only on database design
Which of the following is NOT a characteristic of Object-Oriented Programming?
a) Encapsulation
b) Inheritance
c) Polymorphism
d) Linear Execution
Which phase of OOAD focuses on identifying objects and their relationships?
a) Implementation
b) Object-Oriented Analysis
c) Testing
d) Deployment
Which UML diagram is used to represent a class structure?
a) Sequence Diagram
b) Activity Diagram
c) Class Diagram
d) State Diagram
Which principle of OOP allows a subclass to inherit behavior from a parent class?
a) Polymorphism
b) Encapsulation
c) Inheritance
d) Abstraction
What is the purpose of encapsulation in OOP?
a) To allow access to private data
b) To hide implementation details and protect data
c) To make all class members public
d) To avoid code reusability
Which relationship in OOAD represents “is-a” inheritance?
a) Association
b) Aggregation
c) Composition
d) Generalization
Which UML diagram shows the flow of activities in a system?
a) Class Diagram
b) Sequence Diagram
c) Activity Diagram
d) Object Diagram
What is polymorphism in Object-Oriented Programming?
a) The ability of different classes to have the same attributes
b) The ability of a function or method to take multiple forms
c) The ability to create multiple copies of an object
d) The ability to store multiple objects in an array
Which term describes the process of designing a system using objects?
a) Structured Programming
b) Object-Oriented Design
c) Functional Programming
d) System Testing
Which UML diagram represents object interactions over time?
a) Sequence Diagram
b) Class Diagram
c) Activity Diagram
d) Deployment Diagram
Which design principle promotes programming to an interface rather than an implementation?
a) Single Responsibility Principle
b) Open-Closed Principle
c) Dependency Inversion Principle
d) Law of Demeter
Which UML diagram represents different states of an object?
a) Use Case Diagram
b) State Diagram
c) Sequence Diagram
d) Class Diagram
Which of the following is NOT an advantage of Object-Oriented Design?
a) Code Reusability
b) Better Maintainability
c) Increased Complexity
d) Modularity
Which relationship in OOAD represents “has-a” or whole-part relationship?
a) Association
b) Generalization
c) Aggregation
d) Dependency
Which principle states that a class should only have one reason to change?
a) Open-Closed Principle
b) Single Responsibility Principle
c) Liskov Substitution Principle
d) Interface Segregation Principle
Which of the following best describes abstraction in OOP?
a) Hiding unnecessary details and showing only relevant features
b) Allowing multiple methods to have the same name
c) Creating multiple instances of an object
d) Allowing direct access to private variables
Which design pattern ensures that only one instance of a class exists?
a) Factory Pattern
b) Singleton Pattern
c) Observer Pattern
d) Decorator Pattern
Which UML diagram is used to represent system components and their dependencies?
a) Component Diagram
b) Sequence Diagram
c) Activity Diagram
d) Class Diagram
What is the purpose of an interface in OOP?
a) To implement a class directly
b) To define a contract without implementation
c) To create a subclass
d) To allow multiple inheritance
Which OOP concept allows a subclass to override a method in its parent class?
a) Encapsulation
b) Method Overloading
c) Method Overriding
d) Abstraction
Which UML diagram is used to represent user interactions with a system?
a) Class Diagram
b) State Diagram
c) Use Case Diagram
d) Component Diagram
Which design principle promotes the extension of a class’s functionality without modifying it?
a) Open-Closed Principle
b) Single Responsibility Principle
c) Interface Segregation Principle
d) Dependency Inversion Principle
Which pattern allows an object to change its behavior dynamically?
a) Singleton Pattern
b) State Pattern
c) Factory Pattern
d) Prototype Pattern
Which of the following is NOT a type of UML relationship?
a) Association
b) Aggregation
c) Polymorphism
d) Dependency
Which design pattern is used to create families of related objects without specifying their concrete classes?
a) Singleton Pattern
b) Factory Pattern
c) Abstract Factory Pattern
d) Adapter Pattern
Which UML diagram is used to show the physical deployment of software components?
a) Deployment Diagram
b) Activity Diagram
c) Sequence Diagram
d) Class Diagram
Which principle states that subclasses should be replaceable for their parent classes without breaking the application?
a) Open-Closed Principle
b) Liskov Substitution Principle
c) Dependency Inversion Principle
d) Interface Segregation Principle
Which UML diagram is best suited for modeling object interactions within a time sequence?
a) Class Diagram
b) Sequence Diagram
c) Activity Diagram
d) Use Case Diagram