A

Admin • 828.03K Points
Coach

Q. What functional interface would you use with `String::length` in a stream mapping?

  • (A) Function<String, Integer>
  • (B) Predicate<String>
  • (C) Supplier<Integer>
  • (D) Consumer<String>

Explanation by: Admin
`Function<String, Integer>` matches input String and returns Integer length.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.