← All lessons

Ask the neighbours (KNN)

Step 1 of 21
The idea

The new student

A new student joins your class. Will they like cricket or football?

You don't know them yet. But you can look at the 3 students most like them (same age, same hostel, same hobbies) and go with what most of those 3 like.

To guess about someone new, find the most similar people you already know and take a vote.

That's the entire idea of k-Nearest Neighbours (KNN). k is how many neighbours you ask.