0 votes
in JAVA by
Which of the following interfaces represents a function that accepts an int-valued argument and produces a result of the specified type in Java 8?

a) IntPredicate

b) IntFunction

c) IntConsumer

d) IntSupplier

1 Answer

0 votes
by
Answer: b) IntFunction.

Explanation: The IntFunction interface represents a function that accepts an int-valued argument and produces a result of the specified type, and has a single abstract method apply() that takes an int value as input and returns a result of the specified type.

Related questions

0 votes
asked May 22, 2022 in JAVA by AdilsonLima
0 votes
asked Aug 22, 2022 in Python by Robindeniel
...