A

Admin • 828.03K Points
Coach

Q. Which method converts a Stream into a List?

  • (A) toList()
  • (B) collect(Collectors.toList())
  • (C) toArray()
  • (D) convertToList()

Explanation by: Admin
collect(Collectors.toList()) collects stream elements into a List.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.