Hello anon!
It’s been a while since I announced the new paid Substack. Today’s drop marks the third paid article in our Substack. I’ve also added a 7 day free trial that will allow you to get access to the content below which will give you a quick glance at what is on the way.
Intuition
I’m experimenting with a bit more of a simplified story to get the point across here. Slightly more technical explanation is provided after this section.
Big Pile
Let’s try to build our intuition for algorithms by thinking about finding a book in an imaginary library.
Recall here that an algorithm is simply a series of steps that we perform to get a result. You probably use all sorts of algorithms in your daily lives, even spreading peanut butter on a piece of bread involves an algorithm!
Now the librarians are lazy and have unfortunately thrown the books onto the floor. They’re piled on top of one another and you have no idea what books are in the pile, much less whether or not your desired book exists in this pile.
If you were looking for Dancing Dragon, then you’re in luck because it’s right on top of the pile of books. But if you were looking for A Big Journey, you would have to search through all the other books in the pile to find it lying at the bottom.
This means that at best, we have a single action to perform - picking up the book. But at worst, we have to sift through every single book in the pile. If we had 10 books in the pile, we would need to sift through 10 books. If we had twenty books, we would need to sift through 20 books.