Explore topic-wise MCQs in Technical MCQs.

This section includes 5 Mcqs, each offering curated multiple-choice questions to sharpen your Technical MCQs knowledge and support exam preparation. Choose a topic below to get started.

1.

For Cat and Animal class, correct way of inheritance is

A. Class Cat: public Animal
B. Class Animal: public Cat
C. Both are correct way
D. None is correct way
E.
Answer» B. Class Animal: public Cat
2.

At what point of time a variable comes into existence in memory is determined by its

A. Data type
B. Storage class
C. Scope
D. All of the above
Answer» C. Scope
3.

#include <iostream>using namespace std;class course{   char name[10];  public : void LFC()  {     cout<<"Its course system";  }};class team : public course{    public: void LFC()    {       cout<<"Its team course system";    }};int main(){      team t;      t.LFC();}
7.Can main() function be made private?

A. Yes, always
B. Yes, if program doesn't contain any classes
C. No, because main function is user defined
D. No, never
Answer» E.
4.

#include <iostream>using namespace std;class team{     public : int member;     void LFC()     { 	    cout<<"Its base class";    };};class course:public team{    public :     void LFC()    {       cout<<"Its derived class";     }};int main() { team t; course c;t.LFC();c.LFC();} 
5.C++ was originally developed by

A. Sir Richard Hadlee
B. Clocksin and Mellish
C. Donald E. Knuth
D. Bjame Stroustrup
Answer» E.
5.

The OOPs concept in C++, exposing only necessary information to users or clients is known as

A. Data hiding
B. Encapsulation
C. Hiding complexity
D. Abstraction
Answer» E.