Given the definition of the Vehicle class:
Which action encapsulates the Vehicle class?
A. Make the Vehicle class public.
B. Make the name variable public.
C. Make the setName method public.
D. Make the name variable private.
E. Make the setName method private.
F. Make the getName method private.
i wrote my java and failed yesterday i think its better to cram what the memorandum says? since here the answer says is B. lets talk guys.
and you think because of that that answer is really B?
D
D
D
Correct answer is D.