Advance C++:1st Quiz Structured Vs OOP Languages

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 Aisha Nazir
A
Aisha Nazir
Community Contributor
Quizzes Created: 1 | Total Attempts: 65
Questions: 10 | Attempts: 65

SettingsSettingsSettings
Advance C++:1st Quiz Structured Vs OOP Languages - Quiz


Questions and Answers
  • 1. 

    Structured programming known as?

    • A.

      Modular programming

    • B.

      Systematic programming

    • C.

      Unit programming

    • D.

      Object oriented programming

    Correct Answer
    A. Modular programming
    Explanation
    Modular programming is the correct answer because it refers to a programming approach where a large program is divided into smaller, manageable modules or functions. Each module performs a specific task and can be developed and tested independently. This approach promotes code reusability, maintainability, and readability. It helps in organizing the code into logical units, making it easier to understand and debug. Additionally, modular programming allows multiple programmers to work on different modules simultaneously, enhancing productivity and collaboration.

    Rate this question:

  • 2. 

    Example of OOP language is?

    • A.

      C

    • B.

      C++

    • C.

      Cobol

    • D.

      Pascal

    Correct Answer
    B. C++
    Explanation
    C++ is an example of an object-oriented programming (OOP) language. It was developed as an extension of the C programming language and includes additional features such as classes, objects, and inheritance. These OOP concepts allow for the creation of modular, reusable code and promote code organization and encapsulation. C++ is widely used in various domains such as game development, system programming, and high-performance computing. It provides a balance between low-level control and high-level abstractions, making it a powerful and versatile language for software development.

    Rate this question:

  • 3. 

    Structured programming focuses on?

    • A.

      Data

    • B.

      Processes

    Correct Answer
    B. Processes
    Explanation
    Structured programming focuses on organizing a program into well-defined, modular processes. It emphasizes the use of procedures or functions to break down a program into smaller, manageable tasks. This approach promotes code reusability, readability, and maintainability. By separating the program logic into distinct processes, structured programming allows for easier debugging, testing, and modification of the code. It also helps in improving the overall efficiency and performance of the program by promoting a systematic and disciplined approach to programming.

    Rate this question:

  • 4. 

    Structured programming follow which approach?

    • A.

      Top down approach

    • B.

      Bottom up approach

    Correct Answer
    A. Top down approach
    Explanation
    Structured programming follows the top-down approach. This approach involves breaking down a problem into smaller sub-problems and solving them one by one. In structured programming, the main program is divided into modules or functions, with each module performing a specific task. The program execution starts from the main module and then moves to the sub-modules in a hierarchical manner. This top-down approach allows for easier understanding, debugging, and maintenance of the code.

    Rate this question:

  • 5. 

    Structured programming provide less reuseability.

    • A.

      True

    • B.

      False

    Correct Answer
    A. True
    Explanation
    Structured programming focuses on breaking down a program into smaller, manageable modules or functions. While this approach promotes code organization and readability, it can limit the reusability of code. Since each module is designed to perform a specific task, it may not be easily adaptable or reusable in other parts of the program. In contrast, other programming paradigms like object-oriented programming offer more flexibility and reusability through the use of classes and objects. Therefore, the statement "Structured programming provides less reusability" is true.

    Rate this question:

  • 6. 

    Data moves freely around functions

    • A.

      Structured programming language

    • B.

      OOP

    Correct Answer
    A. Structured programming language
    Explanation
    The given correct answer is "structured programming language" because in structured programming, data is passed between functions using parameters and return values, allowing for the free movement of data. In contrast, Object-Oriented Programming (OOP) focuses on encapsulating data within objects and using methods to manipulate that data, which may restrict the movement of data between functions. Therefore, structured programming languages are more conducive to the free movement of data.

    Rate this question:

  • 7. 

    OOP helps to keep the code?

    • A.

      WET

    • B.

      DRY

    • C.

      Rainy

    Correct Answer
    B. DRY
    Explanation
    OOP helps to keep the code DRY, which stands for "Don't Repeat Yourself". This principle encourages the use of reusable code and modular design, reducing duplication and improving maintainability. By organizing code into classes and objects, OOP allows for encapsulation, inheritance, and polymorphism, which promote code reusability and modularity. This helps to eliminate redundancy and ensures that changes made in one part of the codebase do not require modifications in multiple places. Overall, OOP helps to keep the code concise, efficient, and easier to maintain.

    Rate this question:

  • 8. 

    Mobile Phone,Remote Control is an example of?

    • A.

      Abstraction

    • B.

      Polymorphism

    • C.

      Inheritance

    • D.

      Encapsulation

    Correct Answer
    A. Abstraction
    Explanation
    Mobile phones and remote controls are examples of abstraction because they represent a simplified version of complex systems. Both devices hide the internal workings and complexities of the technology behind a user-friendly interface. Users can interact with these devices without needing to understand the underlying details of how they function. Abstraction allows users to focus on the essential features and functionalities of the device, making it easier to use and understand.

    Rate this question:

  • 9. 

    _____________allow an object to perform in multiple ways.

    • A.

      Inheritance

    • B.

      Polymorphism

    • C.

      Abstraction

    • D.

      Encapsulation

    Correct Answer
    B. Polymorphism
    Explanation
    Polymorphism allows an object to perform in multiple ways. It is a concept in object-oriented programming where an object can take on many forms or have multiple behaviors. This is achieved through method overriding and method overloading. Polymorphism allows different objects to respond differently to the same method call, based on their specific implementation. It promotes code reusability, flexibility, and extensibility in software development.

    Rate this question:

  • 10. 

    Java,python is an example of ?

    • A.

      Structured Programming language

    • B.

      OOP

    Correct Answer
    B. OOP
    Explanation
    Java and Python are both examples of Object-Oriented Programming (OOP) languages. OOP is a programming paradigm that organizes code into objects, which are instances of classes. It focuses on the concept of objects and their interactions, allowing for the creation of reusable code and modular design. In OOP, programs are structured around objects that have properties (attributes) and behaviors (methods). Both Java and Python support the principles of OOP, such as encapsulation, inheritance, and polymorphism, making them suitable for developing complex and scalable applications.

    Rate this question:

Back to Top Back to top
Advertisement
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.