English Русский Contacts Site map Add to favorites
Registration
Login
Master braindump list
New braindumps
Submit a dump
Get latest dump
braindumps.com.ua
flame
3COM (7)
Adobe (1)
BEA (1)
Checkpoint (22)
Cisco (20)
Citrix (21)
CIW (15)
Compaq (0)
CompTIA (51)
CWNA (2)
EMC (2)
Exin (4)
GEJOS (4)
HDI (1)
HP (4)
IBM (13)
Juniper (5)
Linux Prof Institute (LPI) (2)
Lotus (11)
Microsoft (2462)
Network Appliance (2)
Novell (16)
Oracle (423)
PLSQL (1)
PMI (5)
SAS (1)
Sun (87)
Teradata (4)
Login:
Password:
RSS feed

Contacts
Certification links
Links
Authorized user can see question and answers.
Please log in or sign up.

Exam question list:
Show all comments
Sun 310-056: Sun Certified Programmer for J2SE 5.0 Upgrade Exam
#31. Given:
  1. 11. class A {
  2. 12. public void process() { System.out.print(”A,”); }}
  3. 13. class B extends A
  4. 14. public void process() throws lOException {
  5. 15. super.process();
  6. 16. System.out.print(”B”);
  7. 17. throw new lOException();
  8. 16. }}
  9. 19. public static void main(String[] args) {
  10. 20. try { new B().process(); }
  11. 21. catch (lOException e) { System.out.println(Exception); }}
What is the result?

Show comments for this question (0)
Add comments
Link to this question

#32. Given:
  1. 1. public class Boxer1 {
  2. 2. Integer i;
  3. 3. int x;
  4. 4. public Boxer1(int y) {
  5. 5. x = i+y;
  6. 6. System.out.println(x);
  7. 7. }
  8. 6. public static void main(String[] args) {
  9. 9. new Boxer1 (new lnteger(4));
  10. 10. }
  11. 11.}
What is the result?

Show comments for this question (0)
Add comments
Link to this question

#33. Given:
  1. 31 .//some code here
  2. 32. try {
  3. 33. // some code here
  4. 34. // catch (SomeException se) {
  5. 35. // some code here
  6. 36. } finally {
  7. 37. // some code here
  8. 38. }
Under which three circumstances will the code on line 37 be executed? (Choose three.)

Show comments for this question (0)
Add comments
Link to this question

#34. Given:
  1. 11. public static Iterator reverse(List list) {
  2. 12. Collections.reverse(list);
  3. 13. return list.iterator();
  4. 14. }
  5. 15. public static void main(String[] args) {
  6. 16. List list= newArrayList();
  7. 17. list.add(1); list.add(2); list.add(3);
  8. 18. is. for (Object obj: reverse(list))
  9. 19. System.out.print(obj + “ , “ );
  10. 20. }
What is the result?

Show comments for this question (0)
Add comments
Link to this question

#35. Given:
  1. 1. class Pizza {
  2. 2. java.util.ArrayList toppings;
  3. 3. public final void addTopping(String topping) {
  4. 4. toppings.add(topping);
  5. 5. }
  6. 6. }
  7. 7. public class PepperoniPizza extends Pizza {
  8. 8. public void addTopping(String topping) {
  9. 9. System.out.println(”Cannot add Toppings”);
  10. 10. }
  11. 11. public static void main(String[] args) {
  12. 12. Pizza pizza = new PepperoniPizza();
  13. 13. pizza .addTopping(“Mushrooms”);
  14. 14. }
  15. 15. }
What is the result?

Show comments for this question (0)
Add comments
Link to this question

#36. Given:
  1. 1. package test;
  2. 2.
  3. 3. class Target {
  4. 4. public String name = “hello”;
  5. 5. }
What can directly access and change the value of the variable name?

Show comments for this question (0)
Add comments
Link to this question

#37. Given:
  1. 11. abstract class Vehicle
  2. { public mt speed() (return 0; }}
  3. 12. class Car extends Vehicle
  4. { public mt speed() (return 60; }}
  5. 13. class RaceCar extends Car
  6. { public mt speed() { return 150; }}
  7. 21. RaceCar racer = new RaceCar();
  8. 22. Car car = new RaceCar();
  9. 23. Vehicle vehicle = new RaceCar();
  10. 24. System .out.println(racer.speed() + “ , “ + car.speed()
  11. 25. + “, “ vehicle.speed());
What is the result?

Show comments for this question (0)
Add comments
Link to this question

#38. Click the Exhibit button.
What is the result?

Show comments for this question (0)
Add comments
Link to this question

#39. Given:
  1. 10. abstract class A {
  2. 11. abstractvoid a1();
  3. 12. void a2() { }
  4. 13. }
  5. 14. class B extends A {
  6. 15. void a1(){ }
  7. 16, void a2 (){ }
  8. 17. }
  9. 18. class C extends B (void do { } }
  10. And:
  1. Ax = new B();
  2. C y = new C();
  3. A z = new C();
What are four valid examples of polymorphic method calls? (Choose four.)

Show comments for this question (0)
Add comments
Link to this question

#40. Given:
  1. 10: public class Hello {
  2. 11: String title;
  3. 12: intvalue;
  4. 13: public Hello() {
  5. 14: title += “ VVorld”;
  6. 15: }
  7. 16: public Hello(int value) {
  8. 17: this.value = value;
  9. 18: title = “Hello”;
  10. 19: Hello();
  11. 20: }
  12. 21: }
and:
  1. 30: Hello c = new Hello(5);
  2. 31: System.out.println(c.title);
What is the result?

Show comments for this question (0)
Add comments
Link to this question


 [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] ... [12 
Up ^ gen. 0.296 Server date 05:37 10-01-2009 Developed by Zip © 2006 Up ^
Forum
Start online exam simulation
Master braindump