InterviewSolution
| 1. |
If You Want To Convert A Base Type To A Derived Type, What Type Of Conversion Do You Use? |
|
Answer» Explicit CONVERSION as shown below. // Explicit conversion is REQUIRED to cast BACK to derived type. The CODE below will compile but throw an exception at run time if the right-side object is not a Car object. Explicit conversion as shown below. // Explicit conversion is required to cast back to derived type. The code below will compile but throw an exception at run time if the right-side object is not a Car object. |
|