A

Admin • 831.35K Points
Coach

Q. Which operation simulates queue behavior using Deque?

  • (A) push() and pop()
  • (B) offerLast() and pollFirst()
  • (C) addLast() and removeLast()
  • (D) add() and pop()
  • Correct Answer - Option(B)
  • Views: 16
  • Filed under category Java
  • Hashtags: Java Deque

Explanation by: Admin
offerLast() and pollFirst() simulate queue behavior (FIFO).

You must be Logged in to update hint/solution

Discusssion

Login to discuss.

Be the first to start discuss.