C++ Programming Quiz


Play this c++ quiz that will help you to excel in C++ certification exams, placements etc. This C++ programming quiz consist of 10 questions that you need to solve in 10 minutes. We’ve specially designed this quiz so that you can quickly acquaint to the pattern of questions you can be asked in placement drives, certification exams etc. This C++ programming test enables you to assess your knowledge of C++ programming.

Take the Free Practice Test



C++ MCQs

Practice C++ MCQ Questions, which will help you to understand C++ programming related concepts and also helps you to prepare for placements, technical rounds, interviews, competitive exams etc.

C++ Quiz

Try Free C++ Quiz, to start a quiz you need to login first, after login you will get start quiz button and then by clicking on that you can start quiz. You will get 10 Minutes to answer all questions.

C++ Quiz

1. What is the output of this program?

#include <iostream>

using namespace std;
int main()
{
    char *ptr;
    char Str[] = "abcdefg";
    ptr = Str;
    ptr += 5;
    cout << ptr;
    return 0;

}  

fg
cdef
defg
abcd

2. Which of the following is not a member of class?

Static Function.
Friend Function
Const Function
Virtual Function

3. Which of the following statement is correct?

Only one parameter of a function can be a default parameter.
Minimum one parameter of a function must be a default parameter.
All the parameters of a function can be default parameters.
No parameter of a function can be default.

4. What is the difference between direct and indirect recursion?

Indirect recursion is faster than direct recursion
Direct recursion is faster than indirect recursion
Direct recursion calls itself directly, while indirect recursion calls another function
Indirect recursion calls itself directly, while direct recursion calls another function

5. From where does the template class derived?

Regular non-templated C++ class
Templated class
Both A or B
None of the above

6. C++ developed in?

1977
1978
1979
1980

7. Which of the following is correct option?

Compiler Error
8 10
8 8
10 8

8. C++ was originally developed by

Sir Richard Hadlee
Clocksin and Mellish
Donald E. Knuth
Bjame Stroustrup

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

Data type
Storage class
Scope
All of the above

10. Which of the following advantages we lose by using multiple inheritance?

Dynamic binding
Polymorphism
Both Dynamic binding & Polymorphism
None of the mentioned

Results