An algorithm is a precise, step-by-step procedure for getting something done — a recipe a computer (or a person) can follow to turn inputs into a reliable output. Clear steps, in order, that reliably reach the intended result. In everyday use, the algorithm also names the ranking software behind a feed or a search page.
Named for the 9th-century Persian mathematician al-Khwārizmī, whose Latinised name gave Medieval Latin algorismus and Middle English algorisme; the th spelling appears only in the 1690s, refashioned through French under a mistaken link to Greek arithmos, 'number.'
// Where it sits
Any ordered set of steps is an algorithm — from tying a shoelace to a search engine. Complexity varies wildly; the core idea doesn't.
What it really means
An algorithm is a recipe with the romance — and the vagueness — removed: a set of clear steps, in order, that turns something you have (ingredients, data, a question) into something you want (a cake, a decision, a sorted list). The magic word hides a mundane idea — if you can write down how to do a thing so precisely that anyone, or any machine, could follow it and get the same result, you've written an algorithm.
What makes them feel modern is scale. A person follows a recipe a few times a day; a computer can run an algorithm's steps millions of times a second, which is how a few lines of logic end up deciding what videos you see, which posts rise, and whether a loan is approved. The steps themselves are often simple. It's the speed and reach that turn them into something close to power.
Which is also why "it's just the algorithm" is never quite the whole truth. Algorithms aren't neutral forces of nature; they're written by people, trained on data people chose, tuned toward goals people set. Understanding the word matters precisely because so much of modern life is now sorted, ranked, and recommended by these quiet recipes — and recipes, of course, reflect whoever wrote them.
Where it comes from
His name became 'algorism', then 'algorithm' — a procedure named after the man who formalised such methods.
Myths & misconceptions
An algorithm means AI.
Any clear step-by-step procedure is close to one — though Knuth uses the cooking recipe as his counter-example, since 'a dash of salt' is not definite enough to qualify. Most algorithms have nothing to do with AI.
Algorithms are neutral and objective.
They reflect the data they learn from and the choices of their makers, so they can carry and even amplify human bias.
How it unfolds
Input
The algorithm takes in one or more inputs — data, a question, a starting state.
Steps
It runs a defined sequence of operations, in order, each one clear and repeatable.
Decisions
Along the way it may branch — 'if this, do that; otherwise, do the other' — to handle different cases.
Output
It returns a result: a sorted list, a decision, a prediction, a recommended video. Same input, same output, every time.
Compare & contrast
Algorithm vs program
An algorithm is the logic — the ordered steps to solve a problem, independent of any language. A program is that logic written out in code a specific computer can actually run. One is the recipe; the other is the recipe typed up for a particular kitchen.
| // | Algorithm | Program |
|---|---|---|
| Is | The method / logic | The written code |
| Depends on | No language | A programming language |
| Exists as | An idea / steps | A runnable file |
| Analogy | The recipe | The recipe, typed up |
How it connects
- Doomscrollingthe feed you can't leave is shaped by a recommendation algorithm.
- Parasocial Relationshipalgorithms keep surfacing the same creators until they feel like friends.
Questions people ask
- What is an algorithm in simple terms?
- An algorithm is a step-by-step set of instructions for solving a problem or completing a task — like a recipe. Give it the same inputs and it follows the same steps to reach the same predictable result. Computers use algorithms to turn data into decisions.
- What is an everyday example of an algorithm?
- The steps to tie your shoelaces, the method you were taught for long division, or the process of looking up a word in a dictionary. Each is a clear, ordered set of steps that anyone can follow to get the same result — which is exactly what an algorithm is. A cooking recipe is the classic near-miss: Knuth uses it as his counter-example, since 'a dash of salt' is not definite enough to qualify.
- Do algorithms have to involve computers?
- No. The concept is older than computers — it's just a defined procedure. Computers made algorithms powerful because they can run millions of steps instantly, but a knitting pattern or long-division method is an algorithm too.
- Can algorithms be biased?
- Yes. An algorithm is only as neutral as its data and its designers' choices. If it learns from biased data, it can reproduce or amplify that bias — which is why the fairness of algorithms in hiring, lending, and feeds is so heavily debated.