PRO192_-_C1_-_FE_-_SU_2023_391.webp
H

PRO192_-_C1_-_FE_-_SU_2023_391.webp

(Choose 1 answer)
Consider the following code:
1. Dog rover, fido;
2. Animal anim;
3.
4. rover = new Dog();
5. anim rover;
6. fido = (Dog)anim;
Where:
Mammal extends Animal Dog extends Mammal
Which of the following statements is true?
A. Line 5 will not compile.
B. Line 6 will not compile.
C. The code will compile but will throw an exception at line 6.
D. The code will compile and run.
E. The code will compile and run, but the cast in line 6 is not required and can be eliminated
3

Thông tin

Category
PRO192
Thêm bởi
Hohenheim90
Ngày thêm
Lượt xem
3,350
Lượt bình luận
18
Rating
0.00 star(s) 0 đánh giá

Image metadata

Filename
PRO192_-_C1_-_FE_-_SU_2023_391.webp
File size
66.1 KB
Dimensions
1713px x 893px

Share this media

Back
Bên trên Bottom