A

Admin • 825.56K Points
Coach

Q. Which of the following operations does NOT change the number of elements in a Stream?

  • (A) filter()
  • (B) flatMap()
  • (C) map()
  • (D) forEach()

Explanation by: Admin
`forEach()` performs an action on each element, but doesn't alter the stream's content.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.