Saved Bookmarks
| 1. |
What is a deque data structure and its types? What are the applications for deque? |
|
Answer» A deque can be thought of as an array of items, but with one important difference: Instead of pushing and popping items off the end to make room, deques are designed to allow items to be inserted at either end. This property makes deques well-suited for performing tasks such as keeping track of inventory, scheduling tasks, or handling large amounts of data. There are two types of deque:
Following are some real-time applications for deque data structure:
|
|