Data Structures come in many flavors. There’s no one to rule them all. You have to know the tradeoffs so you can choose the right one for the job.
In your day-to-day work, you might not need to re-implement basic data structures. However, knowing how they work internally can help you understand their time complexity better (Remember the chapter How to determine Big-O from code?).
When you are aware of the data structures implementations, you spot when to use one over the other or even extend them to create a new one. We are going to explore the most common data structures' time and space complexity.
In this part we are going to learn about the following linear data structures:
If you want to have a general overview of each one, take a look at the following interactive diagram: