1. If class AClass is derived from class BClass, which one of the following stat
ID: 3568514 • Letter: 1
Question
1. If class AClass is derived from class BClass, which one of the following statements correctly states the constructor call sequence when an object of AClass is instantiated? a) BClass constructor first, AClass constructor secondb) AClass constructor first, BClass constructor second
c) BClass constructor only; the AClass constructor is not called if AClass derived private from BClass
d) AClass constructor only; the BClass constructor is not called if BClass derived private from AClass 2. Which one of the following statements is a correct example of inheritance? a) An automobile has an engine.
b) An automobile is a Mustang.
c) A Mustang is an automobile.
d) An engine is part of an automobile. 3. Which of the following base class members is never inherited by a derived class, regardless of access attributes? a) Mutator
b) Data
c) Accessor
d) Destructor 1. If class AClass is derived from class BClass, which one of the following statements correctly states the constructor call sequence when an object of AClass is instantiated? a) BClass constructor first, AClass constructor second
b) AClass constructor first, BClass constructor second
c) BClass constructor only; the AClass constructor is not called if AClass derived private from BClass
d) AClass constructor only; the BClass constructor is not called if BClass derived private from AClass
Explanation / Answer
1)
BClass constructor first, AClass constructor second
BClass constructor only; the AClass constructor is not called if AClass derived private from BClass
2)
c) A Mustang is an automobile.
d) An engine is part of an automobile.
3)
Destructor
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.