首頁 >> SUN >> SCJP >> "SCJP 310-065"題庫
310-065
Sun Certified Programmer for the Java 2 Platform. SE6.0
SCJP 310-065考試題庫由KillTest認證題庫網資深IT認證講師和SCJP產品專家結合PROMETRIC或VUE的真實310-065考試環境最新原題傾心打造。
題庫覆蓋了當前最新的真實考題,並且全部附有正確答案,我們承諾題庫對SCJP 310-065(Sun Certified Programmer for the Java 2 Platform. SE6.0)考試原題完整覆蓋。310-065題庫助您輕鬆通過認證考試,一次不過全額退款。
Sun Certified Programmer for the Java 2 Platform. SE6.0 |
![]() |
|||
| 認證編號 | Q&A | 更新 | 價格(美元) | |
310-065 |
255 Q&A | 2008-12-01 | $ 89 | |
SCJP 310-065(Sun Certified Programmer for the Java 2 Platform. SE6.0)考題由我們的資深IT認證講師和SCJP產品專家精心打造,包括了當前最新的真實310-065考題,全部附有正確答案。
所有購買KillTest 310-065 題庫的客戶都將得到60天的免費升級服務,保證了客戶的一次通過率。KillTest IT認證題庫網助您一次通過SCJP 310-065考試。
1、本題庫源自合作考試中心的真實考試原題,截屏后由我們的專業團隊匯總整理,再經過合作培訓中心資深IT認證講師對考題校對,保證了認證考試題庫的專業品質,題庫試題正確率100%,對310-065認證考試考題覆蓋率96%以上。您只需在參加SCJP 310-065認證前整體學習下本題庫,必定可以輕鬆完成考試,一次通過認證。
2、KillTest 實行“一次不過全額退款”承諾。如果您購買了我們的《310-065 Exam》考題,只要不是首次通過,憑蓋有PROMETRIC或VUE考試中心鋼印的考試成績單,我們將退還您購買310-065題庫的全部費用,絕對保證您的利益不受到任何的損失。(全額退款詳情)
3、作為亞太地區最專業的IT認證試題題庫供應商,我們提供完善的售後服務,我們對所有購買題庫的客戶提供跟蹤服務,在您購買考題后的60天內,享受免費升級考題服務,如果在這期間,認證考試中心對310-065考題做出修改或變題,我們會在第一時間更新相關題庫,并免費提供給您更新下載。
Sun Certified Programmer for the Java 2 Platform. SE6.0(310-065 Exam)屬於SCJP認證考試中的一門,如果需要取得SCJP證書,您可能還需要參加其他相關考試,詳情可訪問SCJP認證專題,在那裡,你將看到所有SCJP認證相關考試科目。
310-065:下载310-065考试题库演示部分(PDF格式)
310-065题库部分演示(DEMO)
1.Click the Task button.
Correct:
Green choice1---->Yellow Choice1
Green choice2---->Yellow Choice3
Green choice1---->Yellow Choice4
Green choice6---->Yellow Choice5
Green choice4---->Yellow Choice2
2.Given: 1. public class Threads2 implements Runnable { 2. 3. public void run() { 4. System.out.println("run."); 5. throw new RuntimeException("Problem"); 6. } 7. public static void main(String[] args) { 8. Thread t = new Thread(new Threads2()); 9. t.start(); 10. System.out.println("End of method."); 11. } 12. } Which two can be results? (Choose two.)
A.java.lang.RuntimeException: Problem
B.run. java.lang.RuntimeException: Problem
C.End of method. java.lang.RuntimeException: Problem
D.End of method. run. java.lang.RuntimeException: Problem
E.run. java.lang.RuntimeException: Problem End of method.
Correct:D E
3.Which two statements are true? (Choose two.)
A.It is possible for more than two threads to deadlock at once.
B.The JVM implementation guarantees that multiple threads cannot enter into a deadlocked state.
C.Deadlocked threads release once their sleep() method's sleep duration has expired.
D.Deadlocking can occur only when the wait(), notify(), and notifyAll() methods are used incorrectly.
E.It is possible for a single-threaded application to deadlock if synchronized blocks are used incorrectly.
F.If a piece of code is capable of deadlocking, you cannot eliminate the possibility of deadlocking by inserting invocations of Thread.yield().
Correct:A F
4.Given: 7. void waitForSignal() { 8. Object obj = new Object(); 9. synchronized (Thread.currentThread()) { 10. obj.wait(); 11. obj.notify(); 12. } 13. } Which statement is true?
A.This code can throw an InterruptedException.
B.This code can throw an IllegalMonitorStateException.
C.This code can throw a TimeoutException after ten minutes.
D.Reversing the order of obj.wait() and obj.notify() might cause this method to complete normally.
E.A call to notify() or notifyAll() from another thread might cause this method to complete normally.
F.This code does NOT compile unless "obj.wait()" is replaced with "((Thread) obj).wait()".
Correct:B
5.Click the Exhibit button. What is the output if the main() method is run?
A.4
B.5
C.8
D.9
E.Compilation fails.
F.An exception is thrown at runtime.
G.It is impossible to determine for certain.
Correct:D
6.Given: 11. class PingPong2 { 12. synchronized void hit(long n) { 13. for(int i = 1; i < 3; i++) 14. System.out.print(n + "-" + i + " "); 15. } 16. } 17. public class Tester implements Runnable { 18. static PingPong2 pp2 = new PingPong2(); 19. public static void main(String[] args) { 20. new Thread(new Tester()).start(); 21. new Thread(new Tester()).start(); 22. } 23. public void run() { pp2.hit(Thread.currentThread().getId()); } 24. } Which statement is true?
A.The output could be 5-1 6-1 6-2 5-2
B.The output could be 6-1 6-2 5-1 5-2
C.The output could be 6-1 5-2 6-2 5-1
D.The output could be 6-1 6-2 5-1 7-1
Correct:B
7.Given: 1. public class Threads4 { 2. public static void main (String[] args) { 3. new Threads4().go(); 4. } 5. public void go() { 6. Runnable r = new Runnable() { 7. public void run() { 8. System.out.print("foo"); 9. } 10. }; 11. Thread t = new Thread(r); 12. t.start(); 13. t.start(); 14. } 15. } What is the result?
A.Compilation fails.
B.An exception is thrown at runtime.
C.The code executes normally and prints "foo".
D.The code executes normally, but nothing is printed.
Correct:B
8.Click the Task button.
Correct:
Green choice2---->Yellow Choice3
Green choice3---->Yellow Choice2
Green choice4---->Yellow Choice4
Green choice5---->Yellow Choice5
Green choice7---->Yellow Choice1
9.Click the Task button.
Correct:
Green choice2---->Yellow Choice1
Green choice3---->Yellow Choice2
Green choice5---->Yellow Choice3
10.Given: 11. public abstract class Shape { 12. private int x; 13. private int y; 14. public abstract void draw(); 15. public void setAnchor(int x, int y) { 16. this.x = x; 17. this.y = y; 18. } 19. } Which two classes use the Shape class correctly? (Choose two.)
A.public class Circle implements Shape { private int radius; }
B.public abstract class Circle extends Shape { private int radius; }
C.public class Circle extends Shape { private int radius; public void draw(); }
D.public abstract class Circle implements Shape { private int radius; public void draw(); }
E.public class Circle extends Shape { private int radius; public void draw() {/* code here */}
F.public abstract class Circle implements Shape { private int radius; public void draw() { /* code here */ }
Correct:B E
11.Given: 11. public class Barn { 12. public static void main(String[] args) { 13. new Barn().go("hi", 1); 14. new Barn().go("hi", "world", 2); 15. } 16. public void go(String... y, int x) { 17. System.out.print(y[y.length - 1] + " "); 18. } 19. } What is the result?
A.hi hi
B.hi world
C.world world
D.Compilation fails.
E.An exception is thrown at runtime.
Correct:D
12.Given: 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?
A.Direction d = NORTH;
B.Nav.Direction d = NORTH;
C.Direction d = Direction.NORTH;
D.Nav.Direction d = Nav.Direction.NORTH;
Correct:D
13.Click the Exhibit button. Which statement is true about the classes and interfaces in the exhibit?
A.Compilation will succeed for all classes and interfaces.
B.Compilation of class C will fail because of an error in line 2.
C.Compilation of class C will fail because of an error in line 6.
D.Compilation of class AImpl will fail because of an error in line 2.
Correct:C
14.Click the Task button.
Correct:
Green choice1---->Yellow Choice2
Green choice2---->Yellow Choice3
Green choice3---->Yellow Choice1
15.Click the Exhibit button. What is the result?
A.4321
B.0000
C.An exception is thrown at runtime.
D.Compilation fails because of an error in line 18.
Correct:D
16.Given: 11. public class Rainbow { 12. public enum MyColor { 13. RED(0xff0000), GREEN(0x00ff00), BLUE(0x0000ff); 14. private final int rgb; 15. MyColor(int rgb) { this.rgb = rgb; } 16. public int getRGB() { return rgb; } 17. }; 18. public static void main(String[] args) { 19. // insert code here 20. } 21. } Which code fragment, inserted at line 19, allows the Rainbow class to compile?
A.MyColor skyColor = BLUE;
B.MyColor treeColor = MyColor.GREEN;
C.if(RED.getRGB() < BLUE.getRGB()) { }
D.Compilation fails due to other error(s) in the code.
E.MyColor purple = new MyColor(0xff00ff);
F.MyColor purple = MyColor.BLUE + MyColor.RED;
Correct:B
17.Given: 11. class Mud { 12. // insert code here 13. System.out.println("hi"); 14. } 15. } And the following five fragments: public static void main(String...a) { public static void main(String.* a) { public static void main(String... a) { public static void main(String[]... a) { public static void main(String...[] a) { How many of the code fragments, inserted independently at line 12, compile?
A.0
B.1
C.2
D.3
E.4
F.5
Correct:D
18.Given: 5. class Atom { 6. Atom() { System.out.print("atom "); } 7. } 8. class Rock extends Atom { 9. Rock(String type) { System.out.print(type); } 10. } 11. public class Mountain extends Rock { 12. Mountain() { 13. super("granite "); 14. new Rock("granite "); 15. } 16. public static void main(String[] a) { new Mountain(); } 17. } What is the result?
A.Compilation fails.
B.atom granite
C.granite granite
D.atom granite granite
E.An exception is thrown at runtime.
F.atom granite atom granite
Correct:F
19.Given: 1. interface TestA { String toString(); } 2. public class Test { 3. public static void main(String[] args) { 4. System.out.println(new TestA() { 5. public String toString() { return "test"; } 6. }); 7. } 8. } What is the result?
A.test
B.null
C.An exception is thrown at runtime.
D.Compilation fails because of an error in line 1.
E.Compilation fails because of an error in line 4.
F.Compilation fails because of an error in line 5.
Correct:A
20.Given: 11. public static void parse(String str) { 12. try { 13. float f = Float.parseFloat(str); 14. } catch (NumberFormatException nfe) { 15. f = 0; 16. } finally { 17. System.out.println(f); 18. } 19. } 20. public static void main(String[] args) { 21. parse("invalid"); 22. } What is the result?
A.0.0
B.Compilation fails.
C.A ParseException is thrown by the parse method at runtime.
D.A NumberFormatException is thrown by the parse method at runtime.
Correct:B
21.Click the Task button.
Correct:
Green choice3---->Yellow Choice6
Green choice2---->Yellow Choice5
Green choice3---->Yellow Choice4
Green choice1---->Yellow Choice3
Green choice3---->Yellow Choice2
Green choice3---->Yellow Choice1
22.Given: 1. public class Blip { 2. protected int blipvert(int x) { return 0; } 3. } 4. class Vert extends Blip { 5. // insert code here 6. } Which five methods, inserted independently at line 5, will compile? (Choose five.)
A.public int blipvert(int x) { return 0; }
B.private int blipvert(int x) { return 0; }
C.private int blipvert(long x) { return 0; }
D.protected long blipvert(int x) { return 0; }
E.protected int blipvert(long x) { return 0; }
F.protected long blipvert(long x) { return 0; }
G.protected long blipvert(int x, int y) { return 0; }
Correct:A C E F G
23.Given: 1. class Super { 2. private int a; 3. protected Super(int a) { this.a = a; } 4. } ... 11. class Sub extends Super { 12. public Sub(int a) { super(a); } 13. public Sub() { this.a = 5; } 14. } Which two, independently, will allow Sub to compile? (Choose two.)
A.Change line 2 to: public int a;
B.Change line 2 to: protected int a;
C.Change line 13 to: public Sub() { this(5); }
D.Change line 13 to: public Sub() { super(5); }
E.Change line 13 to: public Sub() { super(a); }
Correct:C D
24.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; }
Correct:D
25.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?
A.any class
B.only the Target class
C.any class in the test package
D.any class that extends Target
Correct:C
26.Given: 11. abstract class Vehicle { public int speed() { return 0; } 12. class Car extends Vehicle { public int speed() { return 60; } 13. class RaceCar extends Car { public int speed() { return 150; } ... 21. RaceCar racer = new RaceCar(); 22. Car car = new RaceCar(); 23. Vehicle vehicle = new RaceCar(); 24. System.out.println(racer.speed() + ", " + car.speed() 25. + ", " + vehicle.speed()); What is the result?
A.0, 0, 0
B.150, 60, 0
C.Compilation fails.
D.150, 150, 150
E.An exception is thrown at runtime.
Correct:D
27.Given: 5. class Building { } 6. public class Barn extends Building { 7. public static void main(String[] args) { 8. Building build1 = new Building(); 9. Barn barn1 = new Barn(); 10. Barn barn2 = (Barn) build1; 11. Object obj1 = (Object) build1; 12. String str1 = (String) build1; 13. Building build2 = (Building) barn1; 14. } 15. } Which is true?
A.If line 10 is removed, the compilation succeeds.
B.If line 11 is removed, the compilation succeeds.
C.If line 12 is removed, the compilation succeeds.
D.If line 13 is removed, the compilation succeeds.
E.More than one line must be removed for compilation to succeed.
Correct:C
28.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 OO principles will they be promoting?
A.Looser coupling
B.Tighter coupling
C.Lower cohesion
D.Higher cohesion
E.Weaker encapsulation
F.Stronger encapsulation
Correct:A
29.Given: 21. class Money { 22. private String country = "Canada"; 23. public String getC() { return country; } 24. } 25. class Yen extends Money { 26. public String getC() { return super.country; } 27. } 28. public class Euro extends Money { 29. public String getC(int x) { return super.getC(); } 30. public static void main(String[] args) { 31. System.out.print(new Yen().getC() + " " + new Euro().getC()); 32. } 33. } What is the result?
A.Canada
B.null Canada
C.Canada null
D.Canada Canada
E.Compilation fails due to an error on line 26.
F.Compilation fails due to an error on line 29.
Correct:E
30.Click the Task button.
Correct:
Green choice3---->Yellow Choice3
Green choice1---->Yellow Choice5
Green choice4---->Yellow Choice2
Green choice2---->Yellow Choice1
Green choice5---->Yellow Choice4
Green choice4---->Yellow Choice6
KillTest IT認證題庫網專業提供SCJP 310-065最新題庫下載,完全覆蓋310-065考試原題。310-065:SCJP 310-065 Questions and Answers,Sun Certified Programmer for the Java 2 Platform. SE6.0
![]() |
||
![]() |
||
![]() |






