Which data structure should I use?
Read the access pattern in the problem. Frequent lookup by key points to a hash table. Ordered traversal points to a tree. Frequent insertion and deletion at both ends points to a deque. Justify from the pattern rather than from familiarity.
This comes up on Data Structures and Algorithms, where it is answered in the context of the work itself.
Not what you asked?
Ask us the actual question
Send the draft, the rubric or the score report with it. You get a real answer and a price before you commit to anything.