Given the classes Student and CollegeStudent, as described , suppose that joe is an object of Student and jill is an object of CollegeStudent. a. Can joe be the argument of a method whose parameter’s...


Given the classes Student and CollegeStudent, as described , suppose that joe is an object of Student and jill is an object of CollegeStudent.


a. Can joe be the argument of a method whose parameter’s type is CollegeStudent? Why or why not?


b. Can jill be the argument of a method whose parameter’s type is Student? Why or why not?


c. Is joe.getYear() legal? Why or why not?


d. Is jill.getName() legal? Why or why not?



May 18, 2022
SOLUTION.PDF

Get Answer To This Question

Submit New Assignment

Copy and Paste Your Assignment Here