C++ Programming Questions Answers - Set 2
-
15. The function used to define the task assigned to an operator is ?
- Virtual function
- Static function
- Operator function
- Friend function
Answer :
Option C
-
16. The symbol ** __ .
- can be overloaded by changing its datatype.
- cannot be overloaded, as on overloading its meaning shall be changed.
- can be overloaded.
- cannot be overloaded as it is not a C++ operator.
Answer :
Option D
-
17. The objects can directly access ?
- Public members
- Private members
- Both of above
- None of above
Answer :
Option A
-
18. Among following which will give the size of object or type ?
- Calloc
- Malloc
- Sizeof
- Realloc
Answer :
Option C
-
19. How we can define member function outside the class ?
- Using union
- Using structure
- Using pointers
- Using scope resolution
Answer :
Option D
-
20. When a derived class inherits from many base classes, this process is known as ?
- multiple inheritance
- multilevel inheritance
- default inheritance
- multiplex inheritance
Answer :
Option A
-
21. 66. A constructor function is generally defined
- In the private section of a class
- In the public section of a class
- In the protected section of a class
- None of the above
Answer :
Option B