← Quiz: Queues and Deques: all 13 questions
Quiz: Queues and Deques · Question 8 of 13
Which Java class is the recommended general-purpose queue and stack?
Which Java class is the recommended general-purpose queue and stack?
- A.Vector
- B.Stack
- C.ArrayDeque
- D.Hashtable
Answer & explanation
Correct answer: ArrayDeque
ArrayDeque is fast and supports both ends; Stack and Vector are old synchronised classes.
Can you get the rest right without peeking?
Take the timed Quiz: Queues and Deques quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →