Direction d = NORTH;
Nav.Direction d = NORTH;
Direction d = Direction.NORTH;
Nav.Direction d = Nav.Direction.NORTH;
第1题:
A.Point p = new Point();
B.Line.Point p = new Line.Point();
C.The Point class cannot be instatiated at line 15.
D.Line l = new Line() ; l.Point p = new l.Point();
第2题:
A.The application will crash.
B.The code on line 29 will be executed.
C.The code on line 5 of class A will execute.
D.The code on line 5 of class B will execute.
E.The exception will be propagated back to line 27.
第3题:
A.df = new DateFormat();
B.df = Date.getFormat();
C.df = date.getFormat();
D.df = DateFormat.getFormat();
E.df = DateFormat.getInstance();
第4题:
If the center of low pressure is due west of you in the Northern Hemisphere, which wind direction should you expect?
A.South to west
B.South to east
C.West to north
D.North to east
第5题:
class One { void foo() {} } class Two extends One { //insert method here } Which three methods, inserted individually at line 14, will correctly complete class Two?()
第6题:
10. interface Foo { int bar(); } 11. public class Sprite { 12. public int fubar( Foo foo) { return foo.bar(); } 13. public void testFoo() { 14. fubar( 15. // insert code here 16.); 17. } 18. } Which code, inserted at line 15, allows the class Sprite to compile?()
第7题:
定义枚举如下: public enum Direction{ EAST,SOUTH,WEST,NORTH } 下列正确使用该枚举类型的语句是哪项?()
第8题:
public void foo() { /* more code here */ }
private void foo() { /* more code here */ }
protected void foo() { /* more code here */ }
int foo() { /* more code here */ }
void foo() { /* more code here */ }
第9题:
Direction Direction=EAST;
Direction direction=Direction.WEST;
int a- Direction.NORTH;
Direction direction=2;
第10题:
Line l = new Line() ; l.Point p = new l.Point();
Line.Point p = new Line.Point();
The Point class cannot be instatiated at line 15.
Point p = new Point();
第11题:
Point p = new Point();
Line.Point p = new Line.Point();
The Point class cannot be instatiated at line 15.
Line 1 = new Line() ; 1.Point p = new 1.Point();
第12题:
Foo { public int bar() { return 1; } }
new Foo { public int bar() { return 1; } }
newFoo() { public int bar(){return 1; } }
new class Foo { public int bar() { return 1; } }
第13题:
A.public class MinMax<?> {
B.public class MinMax<? extends Number> {
C.public class MinMax<N extends Object> {
D.public class MinMax<N extends Number> {
E.public class MinMax<? extends Object> {
F.public class MinMax<N extends Integer> {
第14题:
A.import utils.*;
B.static import utils.*;
C.import utils.Repetition.*;
D.static import utils.Repetition.*;
E.import utils.Repetition.twice();
F.import static utils.Repetition.twice;
G.static import utils.Repetition.twice;
第15题:
A.Foo { public int bar() { return 1; }
B.new Foo { public int bar() { return 1; }
C.new Foo() { public int bar() { return 1; }
D.new class Foo { public int bar() { return 1; }
第16题:
In the Northern Hemisphere a wind is said to veer when the wind ______.
A.changes direction clockwise, as from north to east, etc
B.changes direction counterclockwise, as from south to east, etc
C.changes direction violently and erratically
D.remains constant in direction and speed
第17题:
10. class Line { 11. public static class Point { } 12. } 13. 14. class Triangle { 15. // insert code here 16. } Which code, inserted at line 15, creates an instance of the Point class defined in Line?()
第18题:
10. class Nav{ 11. public enum Direction { NORTH, SOUTH, EAST, WEST } 12. } 13. public class Sprite{ 14. // insert code here 15. } Which code, inserted at line 14, allows the Sprite class to compile?()
第19题:
Given: 10. class One { 11. void foo() { } 12. } 13. class Two extends One { 14. //insert method here 15. } Which three methods, inserted individually at line 14, will correctly complete class Two?()
第20题:
int foo() { /* more code here */ }
void foo() { /* more code here */ }
public void foo() { /* more code here */ }
private void foo() { /* more code here */ }
protected void foo() { /* more code here */ }
第21题:
Direction d = NORTH;
Nav.Direction d = NORTH;
Direction d = Direction.NORTH;
Nav.Direction d = Nav.Direction.NORTH;
第22题:
Changes direction clockwise,as from north to east,etc
Changes direction violently and erratically
Remains constant in direction and speed
Changes direction counterclockwise,as from south to east,etc
第23题:
int foo() { /* more code here */ }
void foo() { /* more code here */ }
public void foo() { /* more code here */ }
private void foo() { /* more code here */ }
protected void foo() { /* more code here */ }
第24题:
Direction d = NORTH;
Nav.Direction d = NORTH;
Direction d = Direction.NORTH;
Nav.Direction d = Nav.Direction.NORTH;