Object-oriented Analysis And Design Book Quiz

Approved & Edited by ProProfs Editorial Team
The editorial team at ProProfs Quizzes consists of a select group of subject experts, trivia writers, and quiz masters who have authored over 10,000 quizzes taken by more than 100 million users. This team includes our in-house seasoned quiz moderators and subject matter experts. Our editorial experts, spread across the world, are rigorously trained using our comprehensive guidelines to ensure that you receive the highest quality quizzes.
Learn about Our Editorial Process
| By Mgabr
M
Mgabr
Community Contributor
Quizzes Created: 4 | Total Attempts: 8,597
Questions: 30 | Attempts: 7,347

SettingsSettingsSettings
Object-oriented Analysis And Design Book Quiz - Quiz

Get ready for an exciting Object-oriented Analysis And Design Book Quiz. The quiz has medium as well as difficult-level questions. Try to answer all of these correctly. Have fun, and don't forget to put your score in the comment box.


Questions and Answers
  • 1. 

    Consider the following situation: a company realizes projects; each project is executed by a team of employees. Which would be a suitable conceptual UML diagram?  

    • A.

      Diagram A

    • B.

      Diagram B

    • C.

      Diagram C

    • D.

      Diagram D

    Correct Answer
    B. Diagram B
    Explanation
    Diagram B, also known as a class diagram, would be a suitable conceptual UML diagram for the given situation. In this diagram, the classes "Company", "Project", and "Employee" are represented with their respective attributes and relationships. This diagram allows for a clear understanding of how projects are executed by teams of employees within the company.

    Rate this question:

  • 2. 

    Which of these activities COULD occur simultaneously?

    • A.

      A44 and a66

    • B.

      A44, a33, and a22

    • C.

      A22 and a77

    • D.

      A77 and a66

    Correct Answer(s)
    B. A44, a33, and a22
    C. A22 and a77
    Explanation
    The activities that could occur simultaneously are a44, a33, and a22. This means that a44, a33, and a22 can all happen at the same time without any conflicts or dependencies. Additionally, a22 and a77 could also occur simultaneously, indicating that these two activities can happen concurrently.

    Rate this question:

  • 3. 

    What is true about a Sequence Diagram? [2 answers]

    • A.

      It describes the behavior in many Use Cases.

    • B.

      It describes the behavior in a single Use Case.

    • C.

      It describes the behavior of a single object.

    • D.

      It describes the behavior of several objects

    Correct Answer(s)
    B. It describes the behavior in a single Use Case.
    D. It describes the behavior of several objects
    Explanation
    A Sequence Diagram is a type of UML diagram that shows the interactions between objects in a system. It is used to describe the behavior of a system or a specific scenario, typically within a single Use Case. The diagram illustrates the sequence of messages exchanged between objects and the order in which they occur. By showing the interactions between multiple objects, it provides a visual representation of how the objects collaborate to achieve a specific functionality. Therefore, it is true that a Sequence Diagram describes the behavior in a single Use Case and the behavior of several objects.

    Rate this question:

  • 4. 

    What is an Object?

    • A.

      A combination of data

    • B.

      A combination of namespace

    • C.

      A combination of the tasks to be performed

    • D.

      A combination of Array

    Correct Answer
    A. A combination of data
    Explanation
    An object is a combination of data because it consists of variables or properties that store information. These variables can hold different types of data such as numbers, strings, or even other objects. Objects also have methods or functions that define the behavior or actions that can be performed on the data. Therefore, an object is essentially a collection or combination of data and the operations that can be performed on that data.

    Rate this question:

  • 5. 

    Which of the following is an example of encapsulation

    • A.

      The steering wheel of the car

    • B.

      Car

    • C.

      Color of the car

    • D.

      Music system of the car

    Correct Answer
    B. Car
    Explanation
    Encapsulation refers to the process of hiding the internal details and complexities of an object and providing a simple interface for interacting with it. In this context, the car itself is an example of encapsulation because it encapsulates various components such as the engine, steering wheel, music system, etc., within its structure. The car provides a high-level interface (such as pedals, steering wheel, buttons) for the user to interact with, while the internal workings of the car remain hidden.

    Rate this question:

  • 6. 

    Polymorphism reduces the effort required to extend an object system by

    • A.

      Coupling objects together more tightly

    • B.

      Enabling a number of different operations to share the same name

    • C.

      Making objects more dependent on one another

    • D.

      Removing the barriers imposed by encapsulation.

    Correct Answer
    B. Enabling a number of different operations to share the same name
    Explanation
    Polymorphism enables a number of different operations to share the same name. This means that objects can have different implementations of the same method, allowing for flexibility and reusability in the code. It reduces the effort required to extend an object system because new operations can be added without modifying existing code. This promotes code maintenance and scalability in object-oriented programming.

    Rate this question:

  • 7. 

    What is the difference between Assignment and Initialization?

    • A.

      Assignment can be done as many times as desired, whereas initialization can be done only once.

    • B.

      Assignment can be done once, whereas initialization can be done as many times as desired.

    • C.

      Both are the same

    • D.

      None of the above

    Correct Answer
    A. Assignment can be done as many times as desired, whereas initialization can be done only once.
    Explanation
    Assignment and initialization are two different concepts in programming. Assignment refers to the process of giving a value to a variable, which can be done multiple times throughout the program. On the other hand, initialization is the act of giving an initial value to a variable when it is created, which can only be done once. Therefore, the correct answer is "Assignment can be done as many times as desired, whereas initialization can be done only once."

    Rate this question:

  • 8. 

    What is inner class?

    • A.

      Classes defined in other classes.

    • B.

      Classes defined in methods.

    • C.

      Both A & B

    • D.

      Only A

    Correct Answer
    C. Both A & B
    Explanation
    An inner class is a class that is defined within another class. It can be defined either within another class (option A) or within a method (option B). This allows the inner class to have access to the members of the outer class, including private members. The use of inner classes can help to organize code and encapsulate functionality within a specific context.

    Rate this question:

  • 9. 

    What are the advantages of inheritance? 

    • A.

      It permits code reusability. Reusability saves time in program development.

    • B.

      It encourages the reuse of proven and debugged high-quality software, thus reducing problems after a system becomes functional.

    • C.

      Both A & B

    • D.

      Only A

    Correct Answer
    C. Both A & B
    Explanation
    Inheritance has two main advantages. Firstly, it allows code reusability, which means that we can reuse existing code in a new class, saving time and effort in program development. Secondly, it encourages the reuse of proven and debugged high-quality software, which reduces problems and errors in the system once it becomes functional. Therefore, the correct answer is "Both A & B" as both advantages are applicable.

    Rate this question:

  • 10. 

    The return data type of void means  

    • A.

      The void area in memory is returned so that you can populate it.

    • B.

      No data type is returned.

    • C.

      Void is not a valid data type.

    • D.

      None of the above

    Correct Answer
    B. No data type is returned.
    Explanation
    The return data type of void means that no data type is returned. In programming, when a function or method is declared with a void return type, it indicates that the function does not return any value. It is used when the function is intended to perform certain actions or operations without producing a result that needs to be returned. Therefore, the statement "No data type is returned" accurately describes the return data type of void.

    Rate this question:

  • 11. 

    Which statements are not correct about Objects? 

    • A.

      An Object is an instance of a class.

    • B.

      Objects can access both instance and static data.

    • C.

      All classes extend the Object class.

    • D.

      Objects do not permit encapsulation.

    Correct Answer
    D. Objects do not permit encapsulation.
    Explanation
    The statement "Objects do not permit encapsulation" is not correct. Encapsulation is one of the fundamental principles of object-oriented programming, which allows the data and methods of an object to be bundled together and hidden from the outside world. Objects provide encapsulation by encapsulating their internal state and providing public methods to interact with that state. This helps in achieving data abstraction and ensures that the internal implementation details of an object are not exposed to the outside world.

    Rate this question:

  • 12. 

    If an attribute is private, which methods have access to it?

    • A.

      Only those defined in the same class.

    • B.

      Only static methods in the same class.

    • C.

      Only instance methods in the same class.

    • D.

      Only classes in the same package.

    Correct Answer
    A. Only those defined in the same class.
    Explanation
    If an attribute is private, it means that it can only be accessed within the same class. Private attributes are not accessible to other classes, even if they are in the same package. Therefore, the correct answer is that only methods defined in the same class have access to the private attribute.

    Rate this question:

  • 13. 

    What is an aggregate object?

    • A.

      An object instance that has only static methods.

    • B.

      An object instance that has only primitive attributes.

    • C.

      An object instance that contains other objects.

    • D.

      An object that has only primitive attributes and instances methods.

    Correct Answer
    C. An object instance that contains other objects.
    Explanation
    An aggregate object is an object instance that contains other objects. This means that it is composed of multiple objects and can be seen as a collection or container of these objects. The other options provided do not accurately describe an aggregate object. An object with only static methods does not necessarily contain other objects, an object with only primitive attributes does not have the capability to contain other objects, and an object with only primitive attributes and instance methods does not necessarily contain other objects either.

    Rate this question:

  • 14. 

    A class can have many methods with the same name, as long as the number of parameters is different.  This is known as: 

    • A.

      Method Overloading

    • B.

      Method Invocating

    • C.

      Method Overriding

    • D.

      Method Labeling

    Correct Answer
    A. Method Overloading
    Explanation
    Method overloading is a feature in object-oriented programming where a class can have multiple methods with the same name but different parameters. This allows for flexibility and reusability of code, as different versions of the method can be called depending on the number or type of arguments passed. Method overloading is useful when there are similar operations that need to be performed on different types of data or with different input parameters.

    Rate this question:

  • 15. 

    -___________ is a blueprint or prototype that defines the variables and the methods common to all objects of a certain kind.  Select the best word to complete this sentence.

    • A.

      Class

    • B.

      Inheritance

    • C.

      Polymorphism

    • D.

      Aggregation

    Correct Answer
    A. Class
    Explanation
    A class is a blueprint or prototype that defines the variables and the methods common to all objects of a certain kind. It serves as a template for creating objects, allowing them to have similar attributes and behaviors.

    Rate this question:

  • 16. 

    -(A/An) ____________ is a contract in the form of a collection of method and constant declarations. When a class implements (a/an) ____________, it promises to implement all of the methods declared in that ____________.  Select the best word to complete this sentence.

    • A.

      Class

    • B.

      Interface

    • C.

      Object

    • D.

      Exception

    Correct Answer
    B. Interface
    Explanation
    An interface is a contract in the form of a collection of method and constant declarations. When a class implements an interface, it promises to implement all of the methods declared in that interface.

    Rate this question:

  • 17. 

    Object-Oriented Programming

    • A.

      Makes programs more reliable.

    • B.

      Simulates real life.

    • C.

      Uses a lot of intimidating vocabulary, which is not as bad as it sounds.

    • D.

      All of the above.

    Correct Answer
    B. Simulates real life.
    Explanation
    Object-Oriented Programming (OOP) simulates real life by representing objects and their interactions in a program. OOP allows developers to model real-world concepts, such as objects, classes, and inheritance, which makes the program more intuitive and easier to understand. By simulating real life, OOP helps developers design more reliable and maintainable code. It also promotes code reusability and modularity, making it easier to manage and update software systems. The statement "All of the above" is incorrect as it implies that OOP also uses intimidating vocabulary, which is not necessarily true.

    Rate this question:

  • 18. 

    Object-Oriented Programming is characterized by using  

    • A.

      Encapsulation

    • B.

      Inheritance.

    • C.

      Polymorphism.

    • D.

      All of the above.

    Correct Answer
    D. All of the above.
    Explanation
    Object-Oriented Programming (OOP) is a programming paradigm that focuses on creating objects, which are instances of classes, and provides a set of principles to structure and organize code. Encapsulation is one of the fundamental principles of OOP, which involves bundling data and methods together within a class to hide the internal details and provide a clean interface for interacting with the object. Inheritance allows the creation of new classes based on existing ones, inheriting their properties and behaviors. Polymorphism enables objects of different classes to be treated as objects of a common superclass, allowing for flexibility and code reusability. Therefore, all three concepts - encapsulation, inheritance, and polymorphism - are characteristics of Object-Oriented Programming.

    Rate this question:

  • 19. 

    _____ is a method of implementation in which programs are organized as cooperative collections of objects, each of which represents an instance of some class and whose classes are all members of a hierarchy of classes united via inheritance relationships.

    • A.

      Object-oriented design

    • B.

      Object-oriented programming

    • C.

      Object-oriented analysis

    • D.

      Object-oriented database

    Correct Answer
    B. Object-oriented programming
    Explanation
    Object-oriented programming is a method of implementation in which programs are organized as cooperative collections of objects. Each object represents an instance of some class, and the classes are all members of a hierarchy of classes united via inheritance relationships. This approach allows for the encapsulation of data and behavior within objects, promoting code reusability, modularity, and flexibility in software development.

    Rate this question:

  • 20. 

     Language is object-oriented if and only if it satisfies the following requirements:  

    • A.

      It supports objects that are data abstractions with an interface of named operations and a hidden local state.

    • B.

      Objects have an associated type [class].

    • C.

      Types [classes] may inherit attributes from supertypes [superclasses].

    • D.

      All of the above

    Correct Answer
    D. All of the above
    Explanation
    The correct answer is "All of the above". This is because all of the requirements listed in the question are necessary for a language to be considered object-oriented. These requirements include supporting objects as data abstractions with named operations and hidden local state, having objects associated with a type (class), and allowing types (classes) to inherit attributes from supertypes (superclasses). Therefore, a language must satisfy all of these requirements in order to be considered object-oriented.

    Rate this question:

  • 21. 

    ____ is a method of design encompassing the process of object-oriented decomposition and a notation for depicting both logical and physical as well as static and dynamic models of the system under design.

    • A.

      Object-oriented design

    • B.

      Object-oriented programming

    • C.

      Object-oriented analysis

    • D.

      Object-oriented database

    Correct Answer
    A. Object-oriented design
    Explanation
    Object-oriented design is a method of design that involves breaking down a system into smaller, more manageable objects. It includes both logical and physical models of the system, as well as static and dynamic models. This approach allows for better organization and understanding of the system being designed.

    Rate this question:

  • 22. 

    ____ is a method of analysis that examines requirements from the perspective of the classes and objects found in the vocabulary of the problem domain.

    • A.

      Object-oriented design

    • B.

      Object-oriented programming

    • C.

      Object-oriented analysis

    • D.

      Object-oriented database

    Correct Answer
    C. Object-oriented analysis
    Explanation
    Object-oriented analysis is a method of analysis that examines requirements from the perspective of the classes and objects found in the vocabulary of the problem domain. It focuses on understanding the problem domain and identifying the objects and their relationships. This analysis helps in creating a conceptual model of the system, which serves as a foundation for object-oriented design and programming. Object-oriented analysis helps in ensuring that the system design and implementation align with the problem domain and its requirements.

    Rate this question:

  • 23. 

    Major elements of the object model are

    • A.

      Class, Object, Method, Interface

    • B.

      Class, Property, Inheritance

    • C.

      Abstraction, Encapsulation, Modularity, Hierarchy

    • D.

      Abstraction, Class, Polymorphism

    Correct Answer
    C. Abstraction, Encapsulation, Modularity, Hierarchy
    Explanation
    The major elements of the object model are abstraction, encapsulation, modularity, and hierarchy. Abstraction refers to the process of simplifying complex systems by breaking them down into smaller, manageable parts. Encapsulation involves bundling data and methods together into a single unit, known as an object, and hiding the internal details from the outside world. Modularity promotes the organization of code into separate, reusable components. Hierarchy establishes relationships between objects, allowing for inheritance and the creation of specialized classes based on existing ones. These elements are fundamental to object-oriented programming and facilitate the development of efficient and maintainable software systems.

    Rate this question:

  • 24. 

    Minor elements of the object model are :

    • A.

      Class,Object,Method,Interface

    • B.

      Class,Property,Inheritance

    • C.

      Typing, Concurrency, Persistence

    • D.

      Abstraction, Class, Polymorphism

    Correct Answer
    C. Typing, Concurrency, Persistence
    Explanation
    The correct answer is Typing, Concurrency, Persistence. These elements are considered minor in the object model because they are not as commonly discussed or emphasized as the major elements like Class, Object, Method, Interface, Property, Inheritance, and Abstraction. Typing refers to the type system used in the programming language, Concurrency deals with the ability of an object to execute multiple tasks simultaneously, and Persistence refers to the ability of an object to retain its data even after the program terminates.

    Rate this question:

  • 25. 

    An ____  denotes the essential characteristics of an object that distinguish it from all other kinds of objects and thus provide crisply defined conceptual boundaries relative to the perspective of the viewer.  

    • A.

      Abstraction

    • B.

      Encapsulation

    • C.

      Modularity

    • D.

      Hierarchy

    Correct Answer
    A. Abstraction
    Explanation
    Abstraction is the correct answer because it refers to the process of simplifying complex systems by focusing on the essential characteristics and ignoring unnecessary details. In the context of the question, abstraction allows us to define the essential characteristics of an object, which distinguish it from other objects and provide clear conceptual boundaries. This helps in understanding and categorizing objects from the perspective of the viewer.

    Rate this question:

  • 26. 

    Kinds of abstractions are :

    • A.

      Entity, action, virtual machine, coincidental

    • B.

      Class, object, method

    • C.

      Analysis, design, programming

    • D.

      Others

    Correct Answer
    A. Entity, action, virtual machine, coincidental
    Explanation
    The correct answer is the first option, "Entity, action, virtual machine, coincidental." This is because these four terms represent different types of abstractions. An entity is an abstract representation of a real-world object, an action represents a behavior or operation, a virtual machine is an abstraction of a physical computer system, and coincidental abstraction refers to accidental or unintended abstractions. The other options listed do not accurately represent different types of abstractions.

    Rate this question:

  • 27. 

    ____ is An object that represents a useful model of a problem domain or solution domain entity

    • A.

      Entity abstraction

    • B.

      Action abstraction

    • C.

      Virtual machine abstraction

    • D.

      Coincidental abstraction

    Correct Answer
    A. Entity abstraction
    Explanation
    Entity abstraction refers to an object that represents a useful model of a problem domain or solution domain entity. It is a way of simplifying complex systems by focusing on the essential characteristics of an entity and hiding unnecessary details. By using entity abstraction, developers can create more efficient and manageable code by encapsulating the behavior and properties of an entity into a single object. This allows for easier understanding, maintenance, and reuse of the code, making it a valuable concept in software development.

    Rate this question:

  • 28. 

    ____ is An object that provides a generalized set of operations, all of which perform the same kind of function  

    • A.

      Entity abstraction

    • B.

      Action abstraction

    • C.

      Virtual machine abstraction

    • D.

      Coincidental abstraction

    Correct Answer
    B. Action abstraction
    Explanation
    Action abstraction is the correct answer because it refers to an object that provides a generalized set of operations, all of which perform the same kind of function. This means that the object can be used to perform various actions or tasks in a consistent and standardized way. It allows for the simplification and organization of complex systems by grouping similar actions together under a single abstraction.

    Rate this question:

  • 29. 

    ____ is the process of compartmentalizing the elements of an abstraction that constitute its structure and behavior; encapsulation serves to separate the contractual interface of an abstraction and its implementation.

    • A.

      Abstraction.

    • B.

      Encapsulation.

    • C.

      Modularity.

    • D.

      Hierarchy

    Correct Answer
    B. Encapsulation.
    Explanation
    Encapsulation is the process of organizing the elements of an abstraction, such as its structure and behavior, in a way that separates the contractual interface from its implementation. It allows for the hiding of internal details and provides a clear and defined way to interact with the abstraction. This helps to improve the maintainability and reusability of code, as changes made to the implementation do not affect the external interface. Therefore, encapsulation best fits the description provided in the question.

    Rate this question:

  • 30. 

    How do you express that some persons keep animals as pets?

    • A.

      Diagram A

    • B.

      Diagram B

    • C.

      Diagram C

    • D.

      Diagram D

    Correct Answer
    A. Diagram A
    Explanation
    The illustration in Diagram A depicts a person holding a dog on a leash, which is a clear representation of a human keeping an animal as a pet. This visual representation conveys the idea that some individuals choose to have animals as companions in their homes and lives. By showcasing the person walking the dog, the image illustrates the common practice of people forming close bonds with animals, caring for their needs, and providing them with love and attention, all of which are characteristics of pet ownership. In summary, Diagram A effectively communicates the concept that some persons keep animals as pets by visually portraying a human-animal relationship where the animal is cared for and regarded as a companion.

    Rate this question:

Quiz Review Timeline +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Sep 27, 2023
    Quiz Edited by
    ProProfs Editorial Team
  • Dec 23, 2011
    Quiz Created by
    Mgabr
Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.