What kind "Algorithms and Data Structures" are commonly used every day by web developers in their every day life?

I have been searching on the internet, and have found that using Algorithms are already handled by the database to do the heavy lifting( B-Trees (and variations like B+ Trees) are the primary data structures used for indexing in MySQL ) or ( When you write a SQL query, MySQL’s query optimizer uses complex algorithms (e.g., cost-based optimization) to determine the most efficient way to execute that query. ) and backend frameworks also like “Pagination” Algorithms. Only Algorithms such as, an “Algorithm” to perform a tax calculation or to decrement stock inventory from an E-Commerce website, and obviously much more Algorithms like this are used in everyday life, not Quick Sort, Bubble Sort, Linear Search, etc… unless you are building a Programming Language for example and need to implement a “Sorting Algorithm”. And I already know about Arrays, HashMaps, Dictionaries, for Data Structures, but really don’t see the point in Queues( and I am not talking about Message Queues like Redis or RabbitMQ ) or Stacks being used in web development, that is for domains such as “Backend” and “Frontend”. So my question is, what kind of Algorithms and Data Structures do web developers use, and I am asking more on the “Backend web developer” side of things, in every day scenarios that can be explained in detail to this question. So can you tell me what kind of Algorithms and Data Structures you use in every day life and if you use things like Bubble Sort or Linear Search?

Keep in mind that even if you never implement a data structure yourself in your career, you are definitely going to need to understand them so that you can maintain code that others have created for these data structures. And you will need to recognize code that uses specific algorithms in case you need to optimize it or modify it in some way. If you cannot tell what you are looking at, you will mess it up.
(In other words, developers may spend more time reading other people’s old code and fixing it than writing any brand new code of their own).
Just another perspective for you to consider.

How do you think MySQL or backend frameworks were made and by whom? Programmers using algorithms and data structures that you’re talking about.

There is a book called “Algorithms + Data Structures = Programming” which I think is a pretty interesting and thoughtful title.

All programming languages are constantly being worked on and updated by programmers as their daily work.

As you’ve kind of described there are domains like “web dev” where you might be using already implemented libraries to make web frontends or something but there are also domains where you will be implementing these all the time.

It’s kind of like saying why learn HTML when you can just use Wordpress? Why become an engineer when you can just buy a car and drive it?

Check out this podcast. I discovered it recently and it’s been pretty enlightening on this exact topic: https://adspthepodcast.com/

Yes I know, programmers, like the creators of Django for example use Algorithms and Data Structures because its how you create software. But my question was directed towards “Web Developers” and “Backend”, like do web developers instead of using a database like MySQL and implementing a function using a method from a backend framework through the ORM for example to create a controller to query the search bar component or is it common instead using a “searching algorithm” for a search bar using Linear Search for example. That’s my question. What kind of common Algorithms like Quick Sort, Linear Search, Merge Sort, do you commonly use and on what type of web apps, can it be a CRM, ERP, or a simple E-Commerce website, a Expense Tracker website?

I see what you mean and yes it’s an interesting question but again “Algorithms + Data Structures = Programming”.

If you have a new user, you might create a user object {id: 0, name: "John Smith"} and then you will need to write a function with steps to add to the purchase history or fetch payment information from the user object. Algorithms can be made from other algorithms, maybe you will use Math.max() in your function but the code you are writing is a specific algorithm, essentially, and the user object is a data structure.

I’d like to see other answers to this question, since I’m not a web dev. Maybe I was mis-interpreting your question as well like “web devs don’t need to learn DSA”.

Everything is either a data structure or an algorithm. (I mean, there are primitives and stuff, but that’s not the point.) Programming is about building data structures, passing them around, and doing stuff with them. Coursework teaches you about classic models as a teaching tool, not because you’ll ever write a doubly-linked-list in the wild.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.