Question: 12-14 please include explanation You are creating a class which is supposed to use an interface named Measurable. Which of: the following class declaration statements

12-14 please include explanation You are creating a class which is supposed12-14 please include explanation

You are creating a class which is supposed to use an interface named Measurable. Which of: the following class declaration statements will accomplish this? a. public class vessel extends Measurable b. public class vessel interfaces Measurable c. public class vessel implements Measurable d. public class vessel inherits Measurable Refer to the following interface and classes. interface sample {public void someMethod ();} class sampleA implements sample {public void someMethod () {System. out. printIn ("Test in A");}} class sampleB implements sample {public void someMethod () {System. out.println ("Test in B");}} Which of the following declarations are legal? I. Sample A a = new SampleB (); II. Sample s1 = new SampleA (); III. Sample s2 = new Sample (); a. I and II only b. III only c. II and III only d. I only e. II only Which of the following statements about an interface is true? a. An interface can only have instance variables that are public. b. An interface can only have instance variables that are private. c. An interface can only have methods that are private. d. An interface can only have a default (no parameter) constructor. e. An interface can only have methods that are public

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!