derived class object inherits all the members of the base class. Which of these remarks about the inherited member variables is true?
a) Inherited members are not accessible to the derived class functions so can safely be ignored
b) Inherited members are need to be allocated memory and should be initialized at creation of a derived class object.
c) Inherited members are will be automatically managed by the C++ runtime system, so can be safely ignored.
d) Inherited members’ memory allocation must be done by the base class constructor for the base class, which must be called.
e) The base class constructor is the most convenient place to initialize these inherited variables.
b) Inherited members are need to be allocated memory and should be initialized at creation of a derived class object. , d) Inherited members’ memory allocation must be done by the base class constructor for the base class, which must be called. , and e) The base class constructor is the most convenient place to initialize these inherited variables.
These are the reasons you should always include a call to one of the base class constructors when you define a constructor for a derived class.
You might also like to view...
Answer the following statements true (T) or false (F)
a) To refer to a particular location or element within an array, we specify the name of the array and the value of the particular element. b) An array declaration reserves space for the array. c) To indicate that 100 locations should be reserved for integer array p, you write the declaration d) An application that initializes the elements of a 15-element array to zero must contain at least one for statement. e) An application that totals the elements of a two-dimensional array must contain nested for statements.
Companies that do most or all of their business on the Internet are known as
a. venture capitalists. b. dot-coms. c. virtual enterprises. d. cyber-coms.
The ____ command on the File menu is one of your best methods for undoing lots of moves.
A. Undo B. Redo C. Revert D. Reverse
While viewing Web pages, you can navigate from page to page using the Forward and Back buttons, and you can use the ____________________ menu to return to your home page or to view a list of previously viewed Web pages.
Fill in the blank(s) with the appropriate word(s).