AI for students · lesson 2 of 24 · free

How machines learn from examples — AI for students

Machine learning is how AI learns. Instead of writing every rule, people collect many examples and label each one with the right answer — “spam” or “not spam”, “cat” or “dog”. The computer finds the pattern in them. More, varied and correctly labelled examples help; very few examples, wrong labels or only one kind of example make the model learn badly.

▶ Watch how it works

Got it? Practise ↓

AI tip

Show, label, learn — “give many correctly labelled examples so the model can find the pattern”

  1. Machine learning learns patterns from many labelled examples — a label is the right answer tag on each example.
  2. Good for training: many varied examples, correct labels, every type the model will meet, and separate new data for testing.
  3. Bad for training: very few examples, wrong or random labels, only one kind of example, blurry examples, testing on the training data.

Use it for: When you hear that an AI was “trained” and want to know what that means.

Worked example: 🏷️ You are labelling messages to train a spam filter. How should this one be labelled? “Send your password to claim a prize” → spam

  1. It asks for a password and promises a prize — a classic trick.
  2. So this message should be labelled “spam”.

Check: Try it: write 4 short messages, label each “spam” or “not spam”, and ask a friend to label them too — do your labels agree? ✓

▶ Watch it animated

✏️ Practice

Work it out in your head or on paper, type the answer and press Check. Stuck? Press “Show me how”.

Right: 0 · Tried: 0

🏁 Lesson 2 test

20 questions. Check each answer, then go to the next one. Get 16 or more right to pass.

🏅 Sign in with Google to earn the 🧠 Machine Learning Starter badge when you pass — and a certificate when you finish all 8 lessons of Part 1 · What AI is. You can still take the test without signing in.

🖨️ Machine Learning for Kids Worksheet

✨ Free AI tutor

Ask the AI tutor about this lesson

Why does it work? When should you use it? Ask in English, मराठी or हिंदी.

Sign in with Google to ask Free — 20 questions a day.

👩‍🏫 AI for students classes near you — online or at home

Prefer a real teacher? TalentJR teachers take live online classes anywhere in India and visit homes in selected cities. Tell us what you need and our team will call you with timings and fees.

Live online classesSmall groups or 1:1 with a teacher, from home, any city.
Teacher at homeA TalentJR teacher visits your home (selected cities).
At a centreClasses at a TalentJR partner centre near you, where available.
Badges, certificates & gifts A badge for every lesson you pass, a certificate for every part you finish, plus TalentJR Points for daily practice. Computer worksheets Flowcharts, block coding and safe internet.