GIAC
GSSP-JAVA · Question #129
Which of the following pieces of codes will be placed at the line XXX to successfully compile the given class? public interface Publication { String GetDetails(); } public class Book implements…
The correct answer is A. public String GetDetails(){}. See the full explanation below for the reasoning.
Question
Which of the following pieces of codes will be placed at the line XXX to successfully compile the given class? public interface Publication { String GetDetails(); } public class Book implements Publication { //line XXX }
Options
- Apublic String GetDetails(){}
- BObject GetDetails(){}
- Clong GetDetails(){}
- Dprivate String GetDetails(){}
How the community answered
(59 responses)- A75% (44)
- B3% (2)
- C7% (4)
- D15% (9)
Community Discussion
No community discussion yet for this question.