Question: JAVA 1. Assume DerivedClass is derived from BaseClass and we have a reference variable for each: subRef and baseRef , respectively. Assume baseRef has been

JAVA

1. Assume DerivedClass is derived from BaseClass and we have a reference variable for each: subRef and baseRef, respectively. Assume baseRef has been instantiated but subRef has not.

True or False: At this point in the program, we can do the following without a compiler error:

 subRef = (DerivedClass) baseRef;

True

False

2.

The statements

 Card card1, card2, card3, myCard; card1 = new Card(); card2 = card1; 

will cause how many card objects to be instantiated? (only one correct choice):

A 4

B 1
C 0
D 2

E 3

3.

Another name for an object is a(n)...

a class
b exception
c array
d instance

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!