A data structure is a method of organizing data in a virtual system. Think of sequences of numbers, or data tables: these are well-defined data structures. An algorithm is a sequence of steps executed by a computer that takes an input and transforms it into a target output.
Together, data structures and algorithms combine and allow programmers to build whatever computer programs they’d like. A deep study into data structures and algorithms ensures well-optimized and efficient code.
There are many algorithms for different purposes. They interact with different data structures in the same computational complexity scale. Think of algorithms as dynamic underlying pieces that interact with static data structures.
The way data is expressed in code is flexible. Once you understand how algorithms are built, you can generalize across different programming languages. In a sense, it’s a bit like knowing how a related family of languages work syntactically. Once you glimpse the fundamental rules behind programming languages and their organizing principles, you can more easily switch between the different languages and learn each faster.
- Linked lists
- Stacks
- Queues
- Sets
- Maps
- Hash tables
- Search trees
Each of these has its own computational complexity for associated functions like adding items and finding aggregate measures such as the mean for the underlying data structure.
- Search
- Sorting
- Graph/tree traversing
- Dynamic programming
- Hashing and regex (string pattern matching)
© 2022 - Made With ❤️ By Ismailium