单项选择题
Given:
Which statement is true?()
A.The code will compile without changes.
B.The code will compile if public Tree() { Plant(); } is added to the Tree class.
C.The code will compile if public Plant() { Tree(); } is added to the Plant class.
D.The code will compile if public Plant() { this("fern"); } is added to the Plant class.
E.The code will compile if public Plant() { Plant("fern"); } is added to the Plant class.
相关考题
-
单项选择题
Click the Exhibit button. What is the result?()
A. go in Goban go in Goban
B. go in Sente go in Goban
C. go in Goban go in Sente
D. go in Sente go in Sente
E. Compilation fails because of an error in line 17. -
单项选择题
Given: When the doSomething method is called, after which line does the Object created in line 5 become available for garbage collection?()
A.Line 5
B.Line 6
C.Line 7
D.Line 8
E.Line 9
F.Line 10 -
单项选择题
Given: What is the result?()
A.1
B.2
C.12
D.Compilation fails.
E.No output is produced.
F.An exception is thrown at runtime.
