← 🧠 How AI Works

How AI Works · Topic 4 of 9

Machine learning: learning from examples

Machine learning is a way of making AI where the computer learns from many examples instead of being given every rule. Examples often have labels (the right answers) and features (the details the computer looks at).

📌 Key points

  1. Machine learning means a computer learns from examples and gets better at a task.
  2. Programmers do not write every rule. They give the computer lots of examples and a way to learn from them.
  3. A label is the right answer for an example, such as "cat" or "dog", or "spam" or "not spam".
  4. A feature is a detail the computer can look at, such as size, colour, shape or number of legs.
  5. The computer works out which features go with which labels. What it learns is called a model.
  6. The model can then make predictions about new examples it has never seen.
  7. Many apps use machine learning: spam filters, photo apps, voice assistants and translation apps.

📖 Key words

Machine learning
A way of making AI where the computer learns from examples instead of being given every rule.
Example
One item the computer learns from, such as one photo or one email.
Label
The right answer for an example, such as "cat" or "spam".
Feature
A detail the computer looks at, such as colour, size or shape.
Model
What the computer has learned, which it uses to make predictions.

✏️ Worked example

How could a computer learn to tell apples from bananas?

  1. Collect examples: 100 pieces of fruit, each with a label, "apple" or "banana".
  2. Choose features to look at: colour, shape (round or long) and length.
  3. The computer studies all the examples and finds a pattern: long and curved usually means banana; round usually means apple.
  4. Now it sees a new fruit that is round and red. It predicts "apple".
  5. Answer: labels give the right answers, features give the details, and the model links them together.
💡 Remember

Remember: label = the answer, feature = a clue. The computer learns which clues lead to which answer.

Test yourself8 questions from a bank of 20. A new mix every time.
Start the quiz →

It’s bedtime! 😴

It’s late, and even Numo is getting sleepy. The best thing you can do for your learning now is… go to sleep!

✨ Sleep helps you

  • 🧠 remember what you learned today: your brain saves it while you sleep
  • 🌱 grow and stay healthy
  • ⚡ wake up with energy, ready to learn and play
  • 😊 feel happy and calm

🦉 Going to bed late can make you

  • 😩 tired and sleepy at school tomorrow
  • 🤯 find it harder to focus and to remember
  • 😠 grumpy and easily upset
  • 🤧 catch colds more easily

Children your age need 9 to 12 hours of sleep every night. Numo will be right here tomorrow!