AllExam Dumps

DUMPS, FREE DUMPS, VCP5 DUMPS| VMWARE DUMPS, VCP DUMPS, VCP4 DUMPS, VCAP DUMPS, VCDX DUMPS, CISCO DUMPS, CCNA, CCNA DUMPS, CCNP DUMPS, CCIE DUMPS, ITIL, EXIN DUMPS,


READ Free Dumps For Oracle- 1z0-851





Question ID 3683

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?
 

Option A

A. Compilation fails because of an error in line 3.
 

Option B

B.    Compilation fails because of an error in line 7.
 

Option C

C.    Compilation fails because of an error in line 9.
 

Option D

D.    If you define D e = new E(), then e.bMethod() invokes the version of bMethod() defined in Line
5.
 

Option E

E.    If you define D e = (D)(new E()), then e.bMethod() invokes the version of bMethod() defined in
Line 5.
 

Option F

F.    If you define D e = (D)(new E()), then e.bMethod() invokes the version of bMethod() defined in Line 9.
 

Correct Answer F
Explanation


Question ID 3684

Given that: Gadget has-a Sprocket and Gadget has-a Spring and Gadget is-a Widget and Widget has-a Sprocket Which two code fragments represent these relationships? (Choose two.)

 

Option A

A.    class Widget { Sprocket s; }
class Gadget extends Widget { Spring s; }
 

Option B

B.    class Widget { }
class Gadget extends Widget { Spring s1; Sprocket s2; }
 

Option C

C.    class Widget { Sprocket s1; Spring s2; } class Gadget extends Widget { }
 

Option D

D.    class Gadget { Spring s; }
class Widget extends Gadget{ Sprocket s; }
 

Option E

E.    class Gadget { }
class Widget extends Gadget{ Sprocket s1; Spring s2; }
 

Option F

F.    class Gadget { Spring s1; Sprocket s2; } class Widget extends Gadget{ }
 

Correct Answer A,C
Explanation

Send email to admin@getfreedumps for new dumps request!!!