Why is it necessary to learn data structures and algorithms in 2022?
Last Updated : 30 Aug, 2022 | By : Sameer Chauhan
Table of contents
Do you wonder why I should study Data Structures & Algorithm if it has no real-world application? Why do companies ask questions on data structures and algorithms if they aren't relevant to their day-to-day job?
Many new and experienced programmers avoid learning Data Structures and Algorithms because they believe it is too complicated and that it will be useless in real life. So, before we get into the topic, we'll throw a simple problem at you and you'll have to solve it.
๐TRY A FUN ACTIVITY
If you need to search your number in 20000 pages of PDF document (roll numbers are arranged in increasing order) how would you do that?
If you will try to search it randomly or in a sequential manner it will take too much time. You might get frustrated after some time.
You can try another solution which is given belowโฆ
- Go to page no. 10000
- If your roll number is missing but all other roll numbers on that page are lower than yours,
- Go to page no. 15000
- Still if your roll number is not listed, but, all other roll numbers are greater than yours this time.
- Go to the page no. 12500
- Continue the same process and within 30โ40 seconds you will find your roll number. Congratulationsโฆ you just have used Binary Search algorithm unintentionally..
๐However, the question of why Big Tech Companies seek programmers with strong DSA skills remains unanswered. So, let's try to understand....
Engineers working for Google, Microsoft, Facebook, and Amazon-like companies are different and are paid more than others... Why, though? Coding is just the implementation in these companies, and it takes about 20-30% of the time allotted to a project. The majority of the time is spent designing things with the best and most efficient algorithms in order to save the company's resources (servers, computation power, etc). This is the primary reason why interviews in these companies focus on algorithms; they want people who can think outside the box in order to design algorithms that can save the company thousands of dollars.
๐How to become good at Data Structures and Algorithms easily??
The efficient way of learning Data Structures and Algorithms depends on a several factors:
- Your prior knowledge of programming languages and basics of Data Structures & Algorithms
- The reason why you want to learn it
- Required resources like e-books, cheat sheets, a good course to help you start easily with DSA
- And last but not the least, a perfect guide!
๐Free & Cheap Paid resources that you can follow to ace DSA ??
- (PAID) Mastering Data Structures & Algorithms using C and C++ | By Abdul Baari
๐There is no better course available developed exclusively for passing the DSA than this one. The best thing is that you can get the course from UDEMY for a low price and it covers all the topics required to ace coding interviews or even to get ready for Code-a-thons!
2.(FREE) A comprehensive list of free resources that you can follow to ace DSA easily
- Arrays โ The very first and basic topic of DSA. ๐ Basics of the array โ Array lectures by Neso Academy (This is only for the people who want to learn from scratch) ๐ Sliding Window โ Playlist by Aditya Verma ๐ Sorting โ Playlist by mycodeschool
- Greedy โ Videos by Abdul Bari Sir (from 3 to 3.5)
- Hashing โ Video by Abdul Bari Sir
- Stack โ Stack Playlist by Aditya Verma
- Queue โ To understand the basics of the queue go to Jennyโs Lecture
- Recursion โ Recursion Playlist by Aditya Verma
- Linked List โ Playlist by Vivekanand Khyade Sir
- Binary Trees โ Playlist by Vivekanand Khyade Sir, Playlist by Kashisk Mehndiratta
- Binary Search Trees โ Video by mycodeschool
- Strings ๐ Rabin Karp Algo โ Video by Abdul Bari Sir, TECH DOSE ๐ KMP Algo โ Video by Abdul Bari Sir, TECH DOSE
- Backtracking โ Videos by Abdul Bari Sir
- Binary Search โ Playlist by Aditya Verma
- Dynamic Programming โ Playlist byAditya Verma (Best DP lectures on Youtube)
- Heaps โ Playlist by Aditya Verma(If you want to learn basics then first refer Abdul Bari Sir videos)
- Graphs โ Playlist by TECH DOSE (If you want to learn basics then first refer Abdul Bari Sir videos)
- Tries โ Video by TECH DOSE
*Above mentioned list contains everything you need or any topic you need to cover. Make sure you check out each of these resources and ace the DSA like a pro!
Huge thanks! to Geetika Didi for providing with such a comprehensive list
Wishing you all the best!