Data Structures And Algorithms: Why Does It Matter?

Data Structures And Algorithms: Why Does It Matter?

ยท

3 min read

Yup, it's Monday again ๐Ÿ˜‚. A quick recap of what you missed on Saturday and Sunday (yes, I know you don't use LinkedIn over the weekend ๐Ÿ˜‰). On Saturday, we explored the advantages of frameworks in user login and authentication which I built on in writing (on Sunday) about the increasing risks of being a software engineer.

If you'd like to catch up on these articles you can check them out here. Now that we have the pleasantries (and subtle advertising ๐Ÿ˜…) out of the way, let's get to the business of the day. A lot of people will tell you that they're not exactly Monday people, some will go say they're morning people or night owls, the point I'm trying to get at is that a lot of people will tell you they're more productive at some times and less at other times.

car-5548242_1280.jpg

THE NEED FOR SPEED DRIVES DATA STRUCTURES AND ALGORITHMS

But what if we could guarantee a base level of efficiency (in the worst case) and a more than impressive level of performance in the best case? This is why the field of software engineering places a lot of emphasis on data structures and algorithms. In building and running software solutions, speed is a key concern, netizens these days are growing increasingly impatient as such, software engineers have to push the envelope on what is possible by leveraging data structures that can enable programs to run faster.

I've written about other subjects like load balancing, stored procedure, among others (because I can't remember the rest right now ๐Ÿ˜„) which in a way contributes to the speed at which users can leverage software solutions. When you use the search feature on digital platforms, you're querying a database, the process of getting the machine to look for the item that matches what you're looking for among thousands or millions of items is one that can be very tasking.

relatable explanation.jfif

A RELATABLE EXPLANATION

Data structures and algorithms instruct the software solution to search, sort and perform other operations in a way that is not just fast, but intelligent and less resource-intensive. The difference in speed is quite significant as the data being queried increases. For example, SortedList was used to render 25,000 contacts (in a software solution), the process took 32 seconds (I doubt the average netizen would wait that long ๐Ÿ˜‚), BinaryTree was used to render the same 25,000 contacts and it took less than a second ๐Ÿ˜ฒ.

finally.jfif

FINALLY

When data structures and algorithm is properly used, the benefits are as distinct as night and data, we have a lot of digital infrastructures that have to serve millions of users and hold their data. When projects are that huge, performance improvement counts. Do note that over-optimization is a clear waste of time as some projects don't require it. In as much as BinaryTree is faster than SortedList in rendering some type of data, it doesn't mean that sortedList is useless. There's a use-case for everything in code.