A

Admin • 832.27K Points
Coach

Q. What happens when an element is removed from an empty ConcurrentLinkedQueue?

  • (A) It throws an exception
  • (B) It blocks until data is available
  • (C) It returns null
  • (D) It returns 0
  • Correct Answer - Option(C)
  • Views: 17
  • Filed under category Java
  • Hashtags: Java Queue

Explanation by: Admin

`poll()` on an empty ConcurrentLinkedQueue returns null.

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.