单项选择题
What is the result?()
A.Compilation fails. B.An exception is thrown at runtime. C.doStuff x=6,main x=6 D.doStuff x=5,main x=5 E.doStuff x=5,main x=6 F.doStuff x=6,main x=5
What is the result?() A.81B.82C.91D.92E.Compilation fai...
A.81 B.82 C.91 D.92 E.Compilation fails. F.An exception is thrown at runtime.
AteamofprogrammersisreviewingaproposedAPIforanewutility...
多项选择题A team of programmers is reviewing a proposed API for a new utility class.After some discussion, they realize that they can reduce the number of methods in the API without losing any functionality.If they implement the new design, which two principles will they be promoting?()
A.Looser coupling B.Tighter coupling C.Lower cohesion D.Higher cohesion E.Weaker encapsulation F.Stronger encapsulation
WhichManclassproperlyrepresentstherelationship"Manhasab...
单项选择题Which Man class properly represents the relationship "Man has a best friend who is a Dog"?()
A.class Man extends Dog{} B.class Man implements Dog{} C.class Man{private BestFriend dog;} D.class Man{private Dog bestFriend;} E.class Man{private Dog;} F.class Man{private BestFriend;}