Govt. Exams
Entrance Exams
In C++, a pure virtual function is declared by adding '= 0' after the function signature. C++ does not have 'abstract' or 'pure' keywords like Java.
Hierarchical inheritance occurs when one base class is inherited by multiple derived classes. Multiple inheritance is when one class inherits from multiple base classes.
Private members are accessible only within the class itself and to friend functions/classes. They are not accessible to derived classes or external code.
The 'protected' access specifier allows derived classes to access the member while keeping it hidden from external classes. This provides the needed balance for inheritance hierarchies.
The 'this' pointer is an implicit pointer that points to the current object instance. It is used to access members of the current object and to return a reference to the current object.
Function overloading allows multiple functions to have the same name as long as they differ in number, type, or order of parameters. Return type alone is not sufficient.
Polymorphism enables a function to work with objects of different types through a common base class interface, providing flexibility and extensibility.
'Poly' means many and 'morph' means form. Polymorphism allows objects to take many forms through method overloading and overriding.
The base class constructor is always called before the derived class constructor to ensure proper initialization of inherited members.
Private members are accessible only within the same class. Public members are accessible from anywhere, and protected members are accessible in derived classes.
About C++ Programming Practice on iGET
iGET offers 28+ free C++ Programming MCQ questions covering all important topics. Each question is prepared by subject experts and comes with detailed explanations to help you understand concepts deeply, not just memorize answers.
Why prepare with iGET?
100% free access, timed mock tests, instant results with detailed analysis, topic-wise progress tracking, and bookmark feature for revision. Trusted by thousands of aspirants preparing for UPSC, SSC, Bank, Railway, NEET, JEE and other competitive exams across India.
How to use this page effectively
Start by selecting a difficulty level (Easy / Medium / Hard) or pick a specific topic from the topics strip. Attempt questions, check your answer instantly, read the explanation carefully, and bookmark tricky ones for later revision. For full exam-style practice, take a Mock Test from the right sidebar.