goo blog サービス終了のお知らせ 

killtestのIT問題集ブログ

killtestの最新試験参考書を提供し、合格することが保証できます!

killtest Oracle認定Javaプログラマ(OCJ-P)、Java-OCJ-P 310-066-JP問題集

2011-08-12 10:02:12 | 日記
Oracle認定Javaプログラマ(OCJ-P)

killtest 310-066-JP認定資格は、Javaプログラミング言語の包括的なスキルを証明したいプログラマを対象としています。killtest認定資格を取得するには、1つの試験に合格する必要があります。310-066-JP試験を受ける前にOracle認定Javaアソシエイツを取得している必要はありません。

試験番号: 310-066-JP
試験の名称: Java Standard Edition 6 Programmer Certified Professional Upgrade Exam

1. Given:
11. public class Test {
12. public enum Dogs {collie, harrier, shepherd};
13. public static void main(String [] args) {
14. Dogs myDog = Dogs.shepherd;
15. switch (myDog) {
16. case collie:
17. System.out.print("collie ");
18. case default:
19. System.out.print("retriever ");
20. case harrier:
21. System.out.print("harrier ");
22. }
23. }
24. }
What is the result?
A.harrier
B.shepherd
C.retriever
D.Compilation fails.
E.retriever harrier
F.An exception is thrown at runtime.
Answer:D

2. Given:
10. interface Foo {}
11. class Alpha implements Foo {}
12. class Beta extends Alpha {}
13. class Delta extends Beta {
14. public static void main( String[] args ) {
15. Beta x = new Beta();
16. // insert code here
17. }
18. }
Which code, inserted at line 16, will cause a java.lang.ClassCastException?
A.Alpha a = x;
B.Foo f = (Delta)x;
C.Foo f = (Alpha)x;
D.Beta b = (Beta)(Alpha)x;
Answer:B

3. A UNIX user named Bob wants to replace his chess program with a new one, but he is not sure where
the old one is installed. Bob is currently able to run a Java chess program starting from his home directory
/home/bob using the command:
java -classpath /test:/home/bob/downloads/*.jar games.Chess
Bob's CLASSPATH is set (at login time) to:/usr/lib:/home/bob/classes:/opt/java/lib:/opt/java/lib/*.jarWhat is
a possible location for the Chess.class file?
A./test/Chess.class
B./home/bob/Chess.class
C./test/games/Chess.class
D./usr/lib/games/Chess.class
E./home/bob/games/Chess.class
F.inside jarfile /opt/java/lib/Games.jar (with a correct manifest)
G.inside jarfile /home/bob/downloads/Games.jar (with a correct manifest)
Answer:C