Object Oriented System Design Questions and Answers

Object Oriented System Design Questions and Answers

 

SET 1

Question 1
Which of the following are known re-factorings (according to Fowler)?
Select one:
a. None of the given answer
b. Replace Delegation with Inheritance
c. Protect Variations
d. Introduce Association Class


Feedback
The correct answer is: Replace Delegation with Inheritance

Question 2
8. Which of the following process model is best suited for developing object-oriented systems?
Select one:
a. Unified Process model
b. Spiral model
c. Waterfall model
d. Prototype model

Feedback
The correct answer is: Unified Process model

Question 3
5. The object-oriented development life cycle is which of the following?
Select one:
a. Analysis, design, and implementation steps in the given order and using multiple iterations.
b. Analysis, design, and implementation steps in any order and using the steps no more than one time.
c. Analysis, design, and implementation steps in the given order and using the steps no more than one time.
d. Analysis, design, and implementation steps in any order and using multiple iterations.

Feedback
The correct answer is: Analysis, design, and implementation steps in the given order and using multiple iterations.

Question 4
1. Which of the following is iterative, incremental, use case driven and architecture centric?
Select one:
a. UML
b. V-method
c. RUP
d. Component Based Development

Feedback
The correct answer is: RUP

Question 5
9. In the UML, the system as a whole can be represented by a
Select one:
a. Use Case
b. Component
c. Class
d. Supplementary specification

Feedback
The correct answer is: Class

Question 6
2. Time critical systems are called as
Select one:
a. Concurrent Systems
b. Real time Systems
c. Distributed Systems
d. Sequential Systems

Feedback
The correct answer is: Real time Systems

Question 7
4. Creating a new system by adding new components and replacing old ones is called
Select one:
a. Ternary replaceability
b. N-Arayreplaceability
c. Binary replaceability
d. Unary replaceability

Feedback
The correct answer is: Binary replaceability

Question 8
10. _ _ _ _ _ _ _ _ relationship is used to model ‘Inheritance’ property of Object Oriented systems
Select one:
a. Realization
b. Dependency
c. Association
d. Generalization

Feedback
The correct answer is: Generalization

Question 9
7. A Use case captures _ _ _ _ _ _ _ _ _ _ of a system
Select one:
a. Structure
b. Construction
c. Behaviour
d. Organization

Feedback
The correct answer is: Behaviour

Question 10
3. Which of the following is an example of execution component
Select one:
a. EJB
b. COM+ Object
c. CORBA
d. J2EE

Feedback
The correct answer is: COM+ Object

Set 2

Question 1

1. The fact that the same operation may apply to two or more classes is called what
Select one:
a. Inheritance
b. Multiple classifications
c. Encapsulation
d. Polymorphism


Feedback
The correct answer is: Polymorphism

Question 2
10. Actors are connected to use cases only by
Select one:
a. Association relationship
b. Generalization relationship
c. Dependency relationship
d. Realization relationship

Feedback
The correct answer is: Association relationship

Question 3
2. During analysis an architect is concerned about _____.
Select one:
a. Implementation
b. Behavioural
c. Deployment
d. Technology

Feedback
The correct answer is: Behavioural

Question 4
3. Which of the following statements is true about use-case realization?
Select one:
a. It is created by the System Analyst.
b. It lists the different steps performed by a use-case.
c. Its creation is part of the Requirements discipline.
d. It provides traceability from Analysis and Design back to requirements.

Feedback
The correct answer is: It provides traceability from Analysis and Design back to requirements.

Question 5
4. A class is
Select one:
a. a group of objects
b. a class of objects
c. a classification of objects
d. template for objects of a particular type

Feedback
The correct answer is: template for objects of a particular type

Question 6
5. Which of the following relationships are used in a use-case diagram?
Select one:
a. Communication
b. Uses
c. ALL given choices
d. Extends

Feedback
The correct answer is: ALL given choices

Question 7
6. Consider a beverage machine. If the actor is ‘customer’, and the scope is ‘machine’, what is most likely to be found in the main scenario of the use case ‘get drink’?
Select one:
a. Customer enters choice – machine shows price – customer puts in coins – machine delivers drink
b. Enter choice – show price – put in coins – deliver drink
c. Enter choice – if drink available then show price – put in coins – if paid enough then deliver drink
d. Machine sends price to LCD display – customer put coins in slot – coin mechanism verifies amount and tells machine controller – machine controller activates

Feedback
The correct answer is: Customer enters choice – machine shows price – customer puts in coins – machine delivers drink

Question 8
7. Non-functional requirements of Library System are captured in
Select one:
a. Use Case Model
b. Supplementary Specification
c. Vision
d. Glossary

Feedback
The correct answer is: Supplementary Specification

Question 9
8. Which of the following is a functional requirement?
Select one:
a. Usability
b. Behaviour
c. Performance
d. Reliability

Feedback
The correct answer is: Behaviour

Question 10
9. The names of use cases are generally given as
Select one:
a. Verb phrases
b. Adverbs
c. Adjectives
d. Noun phrases

Feedback
The correct answer is: Verb phrases

SET 3

Question 1
6. How do you express that some persons keep animals as pets?
Select one:
a. Diagram C
b. Diagram D
c. Diagram A
d. Diagram B


Feedback
The correct answer is: Diagram A

Question 2
1. What services can be requested from a class, which define the behavior of the class?
Select one:
a. Stereotypes
b. Operations
c. Attributes
d. Names of classes

Feedback
The correct answer is: Operations

Question 3
10. Conceptual class consists only
Select one:
a. Events
b. Attributes
c. Responsibilities
d. Operations

Feedback
The correct answer is: Attributes

Question 4
7. In Library system, the multiplicity of the association between student and book corresponds to
Select one:
a. One-to-one
b. Many-to-many
c. One-to-many
d. Many-to-one

Feedback
The correct answer is: One-to-many

Question 5
5. Which statement is false?
Select one:
a. A use case consists of a many scenarios
b. Post conditions are written in an operations contract and not for use cases
c. A scenario consists of many events
d. An Operation contract is written for an event

Feedback
The correct answer is: Post conditions are written in an operations contract and not for use cases

Question 6
4. Which of the following does not belong to OOAD?
Select one:
a. Domain model
b. Fully dressed use case
c. Swim lane diagram
d. State transition diagram

Feedback
The correct answer is: Fully dressed use case

Question 7
8. The domain model of Library System consists
Select one:
a. Book class with attributes title, author, price and operation getTitle
b. Book class with attributes title, author, price and operations getTitle, getAuthor
c. Book class with attributes title, price
d. Book class with attribute author and operation getAuthor

Feedback
The correct answer is: Book class with attributes title, price

Question 8
2. A boundary class is an analysis class that represents _____.
Select one:
a. An intermediary or interface to something outside the system
b. The interface between the client and middleware tiers in a system
c. The user interface or Presentation layer of a system
d. An API that is supplied by a third-party vendor and used to integrate with an external system

Feedback
The correct answer is: An intermediary or interface to something outside the system

Question 9
9. On a domain model with n different conceptual classes, there can be
Select one:
a. n(n+1) associations
b. n(n-1) associations
c. 2n+1 associations
d. 2n associations

Feedback
The correct answer is: n(n-1) associations

Question 10
3. What is the programming style of the object oriented conceptual model?
Select one:
a. Algorithms
b. Invariant relationships
c. Classes and objects
d. Goals, often expressed in a predicate calculus.

Feedback
The correct answer is: Classes and objects

SET 4

Question 1
6. What is true about a Sequence Diagram?
Select one:
a. None of the given answer.
b. It describes the behaviour in many Use Cases.
c. It describes the behaviour of several objects.
d. It describes the behaviour of a single object.


Feedback
The correct answer is: It describes the behaviour of several objects.

Question 2
1. The benefits of object-oriented modelling are which of the following?
Select one:
a. All of the given choices.
b. Improved communication between users, analysts, etc.
c. The ability to tackle more challenging problems
d. Reusability of analysis, design, and programming results

Feedback
The correct answer is: All of the given choices.

Question 3
2. Constructor operation does which of the following?
Select one:
a. Deletes and existing instance of a class
b. Updates an existing instance of a class
c. All of the given choices.
d. Creates a new instance of a class

Feedback
The correct answer is: Creates a new instance of a class

Question 4
8. Activity diagram is a special kind of
Select one:
a. State Chart Diagram
b. Interaction Diagram
c. Use Case Diagram
d. Component Diagram

Feedback
The correct answer is: State Chart Diagram

Question 5
10. In an Activity Diagram, organizing the activities into groups is called
Select one:
a. Synchronization
b. Joining
c. Swim lane
d. Forking

Feedback
The correct answer is: Swim lane

Question 6
7. Which diagram is NOT commonly used for illustrating use cases?
Select one:
a. Collaboration diagram
b. System sequence diagram
c. Activity diagram
d. Use case diagram

Feedback
The correct answer is: Collaboration diagram

Question 7
9. In an Activity Diagram, transitions belongs to
Select one:
a. Self-Transitions
b. Completion Transitions
c. Trigger Oriented Transitions
d. Internal Transitions

Feedback
The correct answer is: Completion Transitions

Question 8
3. An association class must be created to store the attributes of a ____ relationship among two other classes.
Select one:
a. Many-to-many
b. Many-to-one
c. One-to-one
d. One-to-many

Feedback
The correct answer is: Many-to-many

Question 9
4. The vertical dimension of a sequence diagram represents
Select one:
a. Lines
b. Time
c. Objects
d. Messages

Feedback
The correct answer is: Time

Question 10
5. Which of the following statements is not true regarding activity diagram?
Select one:
a. A solid filled circle represents the final state
b. Transitions can branch and merge (diamond) – alternative computation threads
c. The final state is shown using so called bull’s eye symbol
d. Transitions can fork and re-join (bar line) –concurrent (parallel) computation threads

Feedback
The correct answer is: A solid filled circle represents the final state

SET 5

Question 1
1 Which among the following are not the valid notations for package and component diagram?
Select one:
a. Box
b. Packages
c. Notes
d. Extension Mechanisms


Feedback
The correct answer is: Box

Question 2
10 Which of the following is true?
Select one:
a. A node is a computational resource
b. None of the mentioned
c. All of the mentioned
d. A UML artifact is any physical representation of data used or produced during software development or software product operation

Feedback
The correct answer is: All of the mentioned

Question 3
2 Which of the following is false?
Select one:
a. The main way to extend UML is by constraints, properties, etc
b. All of the mentioned
c. A note is a dog-eared box connected to any model element by a dashed line
d. A dependency relation holds between two entities D and I where change in I does not affect D

Feedback
The correct answer is: A dependency relation holds between two entities D and I where change in I does not affect D

Question 4
3 Which of these depicts the true definition for the UML extensions?
Select one:
a. A property is a characteristic of the entity designated by a model element
b. A stereotype is a UML model element given more specific meaning
c. A constraint is the statement that must be true of the entities designated by one or more model elements
d. All of the mentioned

Feedback
The correct answer is: All of the mentioned

Question 5
4 What is visibility?
Select one:
a. A program entity at a point in a program text if it can be referred to by name at that point
b. All of the mentioned
c. None of the mentioned
d. The portion of a text over which a program entity is visible

Feedback
The correct answer is: The portion of a text over which a program entity is visible

Question 6
5 What are the types of visibility?
Select one:
a. All of the mentioned
b. Non-Local
c. Global
d. Local

Feedback
The correct answer is: All of the mentioned

Question 7
6 A package diagram consists of the following?
Select one:
a. a, b
b. Groupings of Usecases, classes, components
c. Package symbols
d. All of the mentioned
e. Interface

Feedback
The correct answer is: a, b

Question 8
7 What are the Object oriented visibility?
Select one:
a. Protected
b. All of the mentioned
c. Private and Packaged
d. Public

Feedback
The correct answer is: All of the mentioned

Question 9
8 Which of the following are of non-local form ?
Select one:
a. a, b
b. Public
c. b, c
d. Protected and Packaged
e. Private

Feedback
The correct answer is: b, c

Question 10
9 What is reference?
Select one:
a. It is an expression that evaluates to an address where a value is stored
b. It is a variable with the same address as another variable
c. All of the mentioned
d. None of the mentioned

Feedback
The correct answer is: It is an expression that evaluates to an address where a value is stored

SET 6

Question 1
1 A software engineer must design the modules with the goal of high cohesion and low coupling.
Select one:
a. True
b. False


Feedback
The correct answer is: True

Question 2
10 Good coupling is best characterised by which of the following?
Select one:
a. Ensuring that sub-classes are not strongly linked to their superclass.
b. Ensuring that operations in the same class are linked.
c. Keeping the number of message types between objects to a minimum.

Feedback
The correct answer is: Keeping the number of message types between objects to a minimum.

Question 3
2 Independent modules are easier to maintain and test because of.
Select one:
a. Reusable modules are possible.
b. All of the above
c. Error propagation is reduced
d. Code modification is limited,

Feedback
The correct answer is: All of the above

Question 4
3 Independence of module is assessed using two qualitative criteria. What are those criteria?
Select one:
a. Cohesion and coupling.
b. Module and modularity.
c. None of the above
d. Cyclomatic complexity and modularity.

Feedback
The correct answer is: Cohesion and coupling.

Question 5
4 ________ is an indication of the relative interdependence among modules.
Select one:
a. Modularity
b. Cohesion
c. Coupling
d. Cohesion and coupling.

Feedback
The correct answer is: Coupling

Question 6
5 What is/are the characteristics of a well-formed design class?
Select one:
a. High cohesion.
b. All of the above.
c. Low coupling.
d. Primitiveness.

Feedback
The correct answer is: All of the above.

Question 7
6 ___________ is an indication of the relative functional strength of a module.
Select one:
a. Coupling
b. Modularity
c. Cohesion
d. Cohesion and coupling.

Feedback
The correct answer is: Cohesion

Question 8
7 A good software design must have the following attribute.
Select one:
a. High module coupling, high module cohesion.
b. Low module coupling, low module cohesion.
c. High module coupling, low module cohesion.
d. Low module coupling, high module cohesion.

Feedback
The correct answer is: Low module coupling, high module cohesion.

Question 9
8 The Liskov Substitution Principle is best described by which of the following?
Select one:
a. A derived object may be treated as if it is the base object.
b. A derived object should be replaced by its base object.
c. Derived objects should be used instead of base objects.

Feedback
The correct answer is: A derived object may be treated as if it is the base object.

Question 10
9 Which of the following is a beneficial consequence of good cohesion in a class?
Select one:
a. The class will exhibit high levels of encapsulation.
b. The attributes in the class will only be accessed by the operations of that class.
c. The operations in the class will be easier to maintain.

Feedback
The correct answer is: The operations in the class will be easier to maintain.

SET 7

Question 1
1. _______ use interfaces and polymorphism to add a level of indirection to varying APIs in other components.
Select one:
a. Decorator
b. Singleton
c. Adapter
d. Facade


Feedback
The correct answer is: Adapter

Question 2
10. ________ provide an interface for creating families of related or dependent objects without specifying their concrete classes.
Select one:
a. Abstracct Factory
b. Fabrication
c. Factory Method
d. Singleton

Feedback
The correct answer is: Abstracct Factory

Question 3
2. Defines an interface for creating an object, but let the subclasses decide which class to instantiate.It lets the instantiation differ to subclasses.
Select one:
a. Prototype
b. Abstract Factory
c. Factory Method
d. Builder

Feedback
The correct answer is: Abstract Factory

Question 4
3. Attach additional responsibilities to an object dynamically.It provides a flexible alternative to subclassing for extending functionality.
Select one:
a. Adapter
b. Chain of responsibility
c. Composite
d. Decorator

Feedback
The correct answer is: Decorator

Question 5
4. Define a family of algorithms, encapsulate each one, and make them interchangeable. It lets the algorithm vary independently from clients that use it.
Select one:
a. Strategy
b. Visitor
c. Decorator
d. Template method

Feedback
The correct answer is: Strategy

Question 6
5. Define one to many dependency between objects so that when one object change state, all its dependent are notified and updated automatically.
Select one:
a. Mediator
b. Chain of responsibility
c. Event Notification
d. Observer

Feedback
The correct answer is: Observer

Question 7
6. Which design pattern would resolve incompatible interfaces or provide a stable interface to similar components with different interfaces?
Select one:
a. Adapter
b. Visitor
c. Mediator
d. Controller

Feedback
The correct answer is: Adapter

Question 8
7. Which of the following statements are true for Singleton pattern?
Select one:
a. Exactly one instance of a class is allowed, it is a singleton. Objects need a global and single point of access.
b. Define a protected method, “getInstance()”, of the class that returns the singleton.
c. A only
d. Both A and B

Feedback
The correct answer is: Both A and B

Question 9
8. Adapter can be implemented as
Select one:
a. Method adapter
b. Class adapter OR Method adapter
c. Object adapter
d. Class adapter
e. Object adapter OR Class adapter

Feedback
The correct answer is: Object adapter OR Class adapter

Question 10
9. Which of following is NOT structural design pattern?
Select one:
a. Composite
b. Adapter
c. Strategy
d. Bridge

Feedback
The correct answer is: Strategy

SET 8

Question 1
1.The ________ hides a subsystem behind an object.
Select one:
a. Facade
b. Adapter
c. Decorator
d. Composite


Feedback
The correct answer is: Facade

Question 2
10. Define a one-to-many dependency between objects so that when one object changes state, all its dependents are notified and updated automatically..
Select one:
a. Facade
b. Flyweight
c. Observer
d. Adapter

Feedback
The correct answer is: Observer

Question 3
2. The ______ can dynamically register subscribers who are interested in an event and notify them when an event occurs.
Select one:
a. Flyweight
b. Single Class Factory
c. Proxy
d. Publisher

Feedback
The correct answer is: Publisher

Question 4
3. Define the skeleton of an algorithm in an operation, deferring some steps to subclasses. It lets subclasses redefine certain steps of an algorithm without changing the algorithm structure.
Select one:
a. Chain of responsibility
b. Template method
c. Interpretor
d. Prototype

Feedback
The correct answer is: Template method

Question 5
4. Provide an unified interface to a set of interfaces in a subsystem. It defines a higher level interface that makes the subsystem easier to use.
Select one:
a. Facade
b. Adapter
c. Strategy
d. Mediator

Feedback
The correct answer is: Facade

Question 6
5. Provides a way to access the elements of an aggregate object sequentially without exposing its underlying representation.
Select one:
a. Visitor
b. Iterator
c. Composite
d. Command

Feedback
The correct answer is: Iterator

Question 7
6. How to change our design to reuse the logic to place an order and, at the same time, reducing the probability of being affected by changes in interfaces?
Select one:
a. Use Facade
b. Use Observer
c. Use Composite

Feedback
The correct answer is: Use Facade

Question 8
7.________ provide a surrogate or placeholder for another object to control access to it.
Select one:
a. Decorator
b. Adapter
c. Facade
d. Proxy

Feedback
The correct answer is: Proxy

Question 9
8. ______ helps to Attach additional responsibilities to an object dynamically.
Select one:
a. Bridge
b. Facade
c. Composite
d. Decorator

Feedback
The correct answer is: Decorator

Question 10
9. Provide a way to access the elements of an aggregate object sequentially without exposing its underlying representation.
Select one:
a. Use Creator
b. Use Iterator
c. Use Facade
d. Use Adapter

Feedback
The correct answer is: Use Iterator