II PU Computer Science Viva Questions & Answers Feb' 2024
14 Questions
3 Views

Choose a study mode

Play Quiz
Study Flashcards
Spaced Repetition
Chat to lesson

Podcast

Play an AI-generated podcast conversation about this lesson

Questions and Answers

What is the default access specifier of a class in C++?

  • Protected
  • Friend
  • Public
  • Private (correct)
  • What is the operator used to access member functions of a class in C++?

  • :: (scope resolution)
  • + (addition)
  • -> (arrow) (correct)
  • - (subtraction)
  • Which term describes arranging elements in ascending or descending order?

  • Insertion
  • Deletion
  • Searching
  • Sorting (correct)
  • What is a collection of similar objects in C++?

    <p>Class</p> Signup and view all the answers

    What is the condition to apply binary search technique to search an element in an array?

    <p>Elements in the array must be in ascending order</p> Signup and view all the answers

    What is an instance of a class called in C++?

    <p>Object</p> Signup and view all the answers

    What is the purpose of the TR tag in HTML?

    <p>Defining a table row</p> Signup and view all the answers

    What is the operator used to allocate memory dynamically in C++?

    <p>new operator</p> Signup and view all the answers

    What is the purpose of DHTML?

    <p>Creating interactive webpages</p> Signup and view all the answers

    What is the role of the base class in inheritance?

    <p>It provides properties to other classes</p> Signup and view all the answers

    When is a constructor invoked in C++?

    <p>When object is created</p> Signup and view all the answers

    What is the characteristic of OOP implemented using function overloading?

    <p>Polymorphism</p> Signup and view all the answers

    Which tag is used to scroll text from one place to another in HTML?

    <p>&lt;marquee&gt;</p> Signup and view all the answers

    What is the operator used to deallocate memory dynamically in C++?

    <p>delete operator</p> Signup and view all the answers

    Study Notes

    C++ Basics

    • The default access specifier of a class in C++ is private.
    • The operator used to access member functions of a class in C++ is the dot operator (.) or the pointer operator (->).

    Data Structures and Algorithms

    • Arranging elements in ascending or descending order is known as sorting.
    • A collection of similar objects in C++ is called an array.

    Searching and Memory Management

    • The condition to apply binary search technique to search an element in an array is that the array must be sorted.
    • An instance of a class in C++ is called an object.

    HTML

    • The purpose of the TR tag in HTML is to define a row in a table.
    • The tag used to scroll text from one place to another in HTML is the Marquee tag.

    Dynamic Memory Allocation

    • The operator used to allocate memory dynamically in C++ is the new operator.
    • The operator used to deallocate memory dynamically in C++ is the delete operator.

    Object-Oriented Programming

    • The purpose of DHTML is to create interactive and dynamic web pages.
    • The base class in inheritance provides a way to create a new class based on an existing class.
    • A constructor in C++ is invoked when an object is created.
    • The characteristic of OOP implemented using function overloading is polymorphism.

    Studying That Suits You

    Use AI to generate personalized quizzes and flashcards to suit your learning preferences.

    Quiz Team

    Description

    Prepare for your II PU Computer Science viva with these questions and answers covering topics such as member functions, access specifiers, classes, and objects in C++. Test your knowledge before the exam.

    More Like This

    Use Quizgecko on...
    Browser
    Browser