C++ Programming Questions Answers - Set 2
-
1. Classes in c++ are ?
- Fundamental data type
- Primitive data type
- Desired data type
- Not defined
Answer :
Option C
-
2. What is data hiding ?
- It is related with hiding internal object details
- It is related with showing internal object details
- It is related with datatypes
- None of above
Answer :
Option A
-
3. A virtual base class ?
- is qualified as virtual in base class definition.
- do not qualified as virtual in base class definition.
- allows to inherit more than one copy of the base class members.
- strict the path of inheritance.
Answer :
Option A
-
4. What is actual syntax of destructor in c++ ?
- !Classname( )
- @Classname( )
- $Classname( )
- ~Classname( )
Answer :
Option D
-
5. Inheritance is referred to as
- “is a” relationship
- "have a" relationship
- both of above
- none of above
Answer :
Option A
-
6. Operator overloading is ?
- giving new meaning to existing c++ operators
- making c++ operators work with objects
- giving c++ operators more than they can handle
- making new c++ operators
Answer :
Option A
-
7. Which among following is not a valid visibility mode in c++ program ?
- Private
- Public
- Protected
- Limited
Answer :
Option D