MCQOPTIONS
Saved Bookmarks
| 1. |
Assume class B is inherited from class A. Which of the following statements is correct about construction of an object of class B? |
| A. | While creating the object firstly the constructor of class B will be called followed by constructor of class A. |
| B. | While creating the object firstly the constructor of class A will be called followed by constructor of class B. |
| C. | The constructor of only class B will be called. |
| D. | The constructor of only class A will be called. |
| Answer» C. The constructor of only class B will be called. | |