Which modification enables the code to compile?

Given the code fragments:

Which modification enables the code to compile?

Given the code fragments:

Which modification enables the code to compile?

A.
Replace line n1 with:
import p1.A;
Replace line n2 with:
import p1.A;
import p1.p2.B;

B.
Replace line n1 with:
import p1;
Replace line n2 with:
import p1;
import p1.p2;

C.
Replace line n1 with:
import p1.A;
Replace line n2 with:
import p1.*;

D.
Replace line n1 with:
import p1.*;
Replace line n2 with:
import p1.p2.*;



Leave a Reply 5

Your email address will not be published. Required fields are marked *


v10

v10

see question 24, why is the answer different ?