class professor {};
class teacher : public virtual professor {};
class researcher : public virtual professor {};
class myprofessor : public teacher, public researcher {};
Referring to the sample code above, if an object of class
"myprofessor" were created, how many instances of professor
will it contain?
a) 0
b) 1
c) 2
d) 3
e) 4
Answer Posted / alliance group
answer is 1......b option
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Explain data encapsulation?
What are virtual functions in c++?
Declare a class vehicle and make it an abstract data type.
What is a linked list in c++?
Are vectors faster than arrays?
Can we distribute function templates and class templates in object libraries?
How important is c++?
What are the types of array in c++?
How can we read/write Structures from/to data files?
What is the oldest programming language?
What is c++ good for?
Explain 'this' pointer and what would happen if a pointer is deleted twice?
What are stacks?
Why is it called c++?
What is array in c++ example?