최신Oracle Java Standard Edition 5 Programmer Certified Professional - 1Z0-853무료샘플문제
문제1
DRAG DROP
Click the Task button.

DRAG DROP
Click the Task button.

정답:

문제2
Given:
11.
rbo = new ReallyBigObject();
12.
// more code here
13.
rbo = null;
14.
/* insert code here */
Which statement should be placed at line 14 to suggest that the virtual machine expend effort toward recycling the memory used by the object rbo?
Given:
11.
rbo = new ReallyBigObject();
12.
// more code here
13.
rbo = null;
14.
/* insert code here */
Which statement should be placed at line 14 to suggest that the virtual machine expend effort toward recycling the memory used by the object rbo?
정답: D
문제3
Given:
1.interface A { public void aMethod(); }
2.interface B { public void bMethod(); }
3.interface C extends A,B { public void cMethod(); }
4.class D implements B {
5.public void bMethod(){}
6.}
7.class E extends D implements C {
8.public void aMethod(){}
9.public void bMethod(){}
10.
public void cMethod(){}
11.
}
What is the result?
Given:
1.interface A { public void aMethod(); }
2.interface B { public void bMethod(); }
3.interface C extends A,B { public void cMethod(); }
4.class D implements B {
5.public void bMethod(){}
6.}
7.class E extends D implements C {
8.public void aMethod(){}
9.public void bMethod(){}
10.
public void cMethod(){}
11.
}
What is the result?
정답: D
문제4
DRAG DROP
Click the Task button.

DRAG DROP
Click the Task button.

정답:

문제5
Given:
11.
static class A {
12.
void process() throws Exception { throw new Exception(); }
13.
}
14.
static class B extends A {
15.
void process() { System.out.println("B "); }
16.
}
17.
public static void main(String[] args) {
18.
A a = new B();
19.
a.process();
20.
}
What is the result?
Given:
11.
static class A {
12.
void process() throws Exception { throw new Exception(); }
13.
}
14.
static class B extends A {
15.
void process() { System.out.println("B "); }
16.
}
17.
public static void main(String[] args) {
18.
A a = new B();
19.
a.process();
20.
}
What is the result?
정답: A
문제6
Given:
10.
abstract class A {
11.
abstract void a1();
12.
void a2() { }
13.
}
14.
class B extends A {
15.
void a1() { }
16.
void a2() { }
17.
}
18.
class C extends B { void c1() { } }
and:
A x = new B(); C y = new C(); A z = new C();
What are four valid examples of polymorphic method calls? (Choose four.)
Given:
10.
abstract class A {
11.
abstract void a1();
12.
void a2() { }
13.
}
14.
class B extends A {
15.
void a1() { }
16.
void a2() { }
17.
}
18.
class C extends B { void c1() { } }
and:
A x = new B(); C y = new C(); A z = new C();
What are four valid examples of polymorphic method calls? (Choose four.)
정답: B,D,E,F
문제7
Given:
11.
Runnable r = new Runnable() {
12.
public void run() {
13.
System.out.print("Cat");
14.
}
15.
};
16.
Thread t = new Thread(r) {
17.
public void run() {
18.
System.out.print("Dog");
19.
}
20.
};
21.
t.start();
What is the result?
Given:
11.
Runnable r = new Runnable() {
12.
public void run() {
13.
System.out.print("Cat");
14.
}
15.
};
16.
Thread t = new Thread(r) {
17.
public void run() {
18.
System.out.print("Dog");
19.
}
20.
};
21.
t.start();
What is the result?
정답: C
문제8
DRAG DROP
Click the Task button.

DRAG DROP
Click the Task button.

정답:

문제9
Given:
1.package test;
2.3.
class Target {
4.public String name = "hello";
5.}
What can directly access and change the value of the variable name?
Given:
1.package test;
2.3.
class Target {
4.public String name = "hello";
5.}
What can directly access and change the value of the variable name?
정답: B
문제10
Given:
13.
public static void search(List<String> list) {
14.
list.clear();
15.
list.add("b");
16.
list.add("a");
17.
list.add("c");
18.
System.out.println(Collections.binarySearch(list, "a"));
19.
}
What is the result of calling search with a valid List implementation?
Given:
13.
public static void search(List<String> list) {
14.
list.clear();
15.
list.add("b");
16.
list.add("a");
17.
list.add("c");
18.
System.out.println(Collections.binarySearch(list, "a"));
19.
}
What is the result of calling search with a valid List implementation?
정답: A
문제11
Given:
15.
public class Yippee {
16.
public static void main(String [] args) {
17.
for(int x = 1; x < args.length; x++) {
18.
System.out.print(args[x] + " ");
19.
}
20.
}
21.
}
and two separate command line invocations:
java Yippee java Yippee 1 2 3 4
What is the result?
Given:
15.
public class Yippee {
16.
public static void main(String [] args) {
17.
for(int x = 1; x < args.length; x++) {
18.
System.out.print(args[x] + " ");
19.
}
20.
}
21.
}
and two separate command line invocations:
java Yippee java Yippee 1 2 3 4
What is the result?
정답: F
문제12
Given a correctly compiled class whose source code is:
1.package com.sun.sjcp;
2.public class Commander {
3.public static void main(String[] args) {
4.// more code here
5.}
6.}
Assume that the class file is located in /foo/com/sun/sjcp/, the current directory is /foo/, and that the classpath contains "." (current directory).
Which command line correctly runs Commander?
Given a correctly compiled class whose source code is:
1.package com.sun.sjcp;
2.public class Commander {
3.public static void main(String[] args) {
4.// more code here
5.}
6.}
Assume that the class file is located in /foo/com/sun/sjcp/, the current directory is /foo/, and that the classpath contains "." (current directory).
Which command line correctly runs Commander?
정답: A