Take The C++ Basic Programming Quiz!

6 Questions | Total Attempts: 119

SettingsSettingsSettings
Please wait...
Take The C++ Basic Programming Quiz!

Take the C++ basic programming quiz! The C++ language is an upgrade to the C language, and it is better in that it allows procedural programming for intensive functions of CPU and has paved the way for other programming languages. The quiz below is designed to help you see how well you understand the language, how about you give it a shot and see how well you will do!


Questions and Answers
  • 1. 
    Which inheritance type is used in the class given below? class A : public X, public Y {}
    • A. 

      Multilevel Inheritance

    • B. 

      Hybrid Inheritance

    • C. 

      Multiple Inheritance

    • D. 

      Hierarchial Inheritance

  • 2. 
    Which of the following are available only in the class hierarchy chain?
    • A. 

      Public data members

    • B. 

      Protected data members

    • C. 

      Private data members

    • D. 

      Member Functions

  • 3. 
    What will happen if a class is not having any name?
    • A. 

      It cannot have a destructor

    • B. 

      It cannot have a constructor

    • C. 

      It is not allowed

    • D. 

      Both A and B

  • 4. 
    What is true about Constructor ?
    • A. 

      Its name is plural of class name.

    • B. 

      Its name has * symbol before it.

    • C. 

      Its name is same as of class name.

    • D. 

      Its name has # symbol before it.

  • 5. 
    Which among following is correct way of declaring object of a class ?
    • A. 

      Classname Objectname;

    • B. 

      Class Classname Objectname;

    • C. 

      Class Classname Object Objectname;

    • D. 

      Classname Object Objectname;

  • 6. 
    How many types of polymorphisms are supported by C++?
    • A. 

      1

    • B. 

      2

    • C. 

      3

    • D. 

      4