What is an algorithm? (Explained for kids and parents)

Updated May 8, 2026 · 350 words

An algorithm is a set of step-by-step instructions for getting something done. A recipe is an algorithm. A morning routine is an algorithm. The way Spotify decides what song to play next is an algorithm — a much more complicated one. AI is built on top of algorithms.

How to explain it to a 7-year-old

🧒 "It's a recipe for the computer. Like ''to make a peanut butter sandwich: get bread, spread peanut butter, put bread on top.'' If you follow the steps, you get a sandwich. Algorithms are recipes for computers."

How to explain it to a 14-year-old

🎒 "An algorithm is a precisely defined sequence of operations that turns inputs into outputs. Sorting algorithms order lists, search algorithms find things, neural network training algorithms tune weights. ''The algorithm'' you hear about in social media context is a recommendation algorithm."

Real-world examples

  • 🥪 A recipe (literal)
  • 📚 The algorithm that sorts your email inbox by date
  • 🎵 Spotify's "discover" recommendation algorithm
  • 🚗 Google Maps' route-finding algorithm
  • 🤖 ChatGPT's text-generation algorithm (= a learned algorithm)

Two important kinds of algorithms

Hand-written algorithmLearned algorithm (AI)
Where rules come fromA human wrote themComputer learned them from data
ExampleCalculator, spell-checkChatGPT, image classifier
When to preferTasks with clear rulesTasks with too many edge cases for rules

Where this comes up in Chippu

Band B (b2-2, "Types of AI") explains the difference between rule-based and learned algorithms. Band D (d1-1) gets technical.

Related terms

Frequently asked questions

What is the simplest definition of an algorithm?
A set of step-by-step instructions to get something done. A recipe is an algorithm; so is a morning routine; so is the rule a thermostat follows. Computer algorithms are just precisely-written versions.
Are algorithms and AI the same?
No. An algorithm is the *general* idea of step-by-step instructions. AI is a specific kind of algorithm — one that learns its rules from data instead of having them hand-written. All AI involves algorithms; not all algorithms are AI.

Read next