Final Remarks

Here’s a quick summary of what we learned from the “Basic Data Structures” module.

Congratulations! You have successfully completed the “Basic Data Structures” module.

Summary#

In this module, we reviewed the concepts and techniques needed to solve coding interview problems involving basic data structures such as linked lists, stacks, and matrices. In the In-place Reversal of a Linked List pattern, we learned to tackle some of the hardest linked list problems using the same basic set of techniques. In the Stacks pattern, we learned to exploit the LIFO property of stacks and the $O(1)$ access they offer to their last element to design efficient solutions to seemingly hard problems. As a result, we learned to recognize those characteristics of a problem that make it a good fit for the Stacks pattern. In the Matrices pattern, we practiced using common matrix transformations such as scaling, translation, rotation, and reflection, as well as matrix traversals such as zig-zag, spiral, and diagonal traversals. 

Working through the solutions to these problems allowed us to gain experience in solving the core computational problems that arise in a diverse range of domains such as task allocation, e-commerce recommendation systems, parsers, compiler design, natural language processing, calculation engine design, graphics, game design, graphs, and cryptography.

Additional resources#

If you’re looking for more challenges to solve using the patterns in this module, you can hone your skills on these problems:

Pattern Name

Problem Name

In-place Reversal of a Linked List

In-place Reversal of a Linked List

In-place Reversal of a Linked List

In-place Reversal of a Linked List

In-place Reversal of a Linked List

Stacks

Stacks

Stacks

Stacks

Matrices

Matrices

Matrices

What’s next?#

Now that we have learned to solve problems using linked lists, stacks, and matrices, we will cover the use of depth-first and breadth-first traversals to solve problems featuring hierarchical data, in the next module, “Trees.”

Solution: Spiral Matrix

Trees