Exam 1z0-819 All QuestionsBrowse all questions from this exam
Question 50

Which two interfaces are considered to be functional interfaces? (Choose two.)

    Correct Answer: B, E

    A functional interface, according to Java, is an interface that contains exactly one abstract method. Although it can have multiple default or static methods, only one abstract method is allowed. Option B is a functional interface as it has only one abstract method, 'breed(int x)'. Option E qualifies as a functional interface because, despite having multiple methods, it has only one abstract method, 'breed(int x)'—the 'getGERM' method is default and 'equals' is from Object class, which doesn't count toward the abstract methods.

Discussion
d7bb0b2Options: BE

ANSWERS IS B AND E: B: Has a only one SAM (single abstract method) and E: has a single abstract method, cause default and private methods are not considered abrascts, and EQUALS is a method from OBJECT neither tecnically considered abstract

d7bb0b2

C: is a triky cause boolean equals(Objetct obj) must be the method from objetc that no count of SAM, every other implementation is count. boolean equals(Integer i); is count Fexmple

tmuralimanoharOptions: BE

Answer: BE

StavokOptions: BE

B&E are correct TESTED

RP384Options: BE

B and E are correct

Ankit1010Options: BE

B and E are the correct answer