Satya's blog - Algorithms and data structures

Mar 28 2023 21:32 Algorithms and data structures

In day-to-day programming, I rarely think about algorithms and data structures. Binary trees. Sorting.

That's because algorithms are already encapsulated in the standard libraries of the programming languages I use. Most languages like Python, Ruby, and Golang have sort functions.

For most data structure purposes, lists and associative arrays (dictionaries, aka key-value) are enough.

Faster algorithms? Processors are relatively cheap, parallelize it.

Memory? Memory is cheap and if that's not enough, spool it out to disk. If that's slow, parallelize it.

No, what's expensive today is network calls. And that's only because everything's fast enough that we can make API calls -- that's Application Programming Interface -- over the Internet.

Of course there are still situations where algorithms and data structures matter. The preceding just talks about 90% of general programming these days: websites and backends. Someone still has to make the standard and not-so-standard libraries of all these languages work, and if you're in embedded-devices land then all bets are off.