mcqs bucket

  • C++ Mcqs Questions | MCQs Bucket Largest Mcqs Website

    mcqsbucket

      Best guide for exams of all nature, Competitive exams and Interviews
Here is the MCQs guide for the topic of C++. you will find various types of questions along with there answers in this
Q. What is the output of the following code.
int i=5,j=6,k=7,n=3;
cout< cout<

A.
46 and 1
B.
50 and 80
C.
45 abd 2


Show Answer
Q. What is the output pf the following code?
int x=20,y=35; x=y++ + x++; cout<

A.
5794
B.
2035
C.
2136
D.
6070


Show Answer
Q. We can create objects of the abstract class.
A.
True
B.
False


Show Answer
Q. Which of the followings is/are not keyword in CPP?
A.
asm
B.
boolean
C.
mutable


Show Answer
Q. When a child class inherits traits from more than one parent class, this type of inheritance is called _______________ inheritance.
A.
Hierarchical
B.
Hybrid
C.
Multilevel
D.
Multiple


Show Answer
Q. Which of the following statements are not true about destructor?
A.
It is invoked when object goes out of the scope
B.
Like constructor it can also have parameters
C.
It can be virtual


Show Answer
Q. A function can be declared as friend maximum only in two classes
A.
True
B.
False


Show Answer
Q. Assigning one or more function body to the same name is called ____________ .
A.
Function Overriding
B.
Function Overloading
C.
All
D.
None


Show Answer
Q. Find the wrong statement about Abstract Class.
A.
We can’t create its objects
B.
We can’t create pointers to an abstract class.
C.
It contains at least one pure virtual function
D.
We can create references to an abstract class.


Show Answer
Q. Runtime polymorphism is achieved only when a virtual function is accessed through a pointer to the base class.
A.
True
B.
False


Show Answer