Which method adds an element at the front of the Deque?

  1. add()
  2. offerFirst()
  3. push()
  4. insert()
Correct answer offerFirst()

Explanation

offerFirst() adds an element at the front of the Deque.

Update: Admin added a tag on this question

Topics

By Admin · · 37 views