Culture of India

How can we measure differences between two things?

Culture of India

How can we measure differences between two things?

Imagine you have two strings of characters, like "hello" and "hallo". You want to know how many characters differ between them.

Think of each character in the strings as a unique puzzle piece. To find out how many pieces differ, you compare each piece in the same position in both strings and count the mismatches.

Example

Comparing "hello" and "hallo", 'e' and 'a' differ in the second string.

Remember this

The Hamming distance counts the number of positions at which the corresponding characters are different.

Related concepts

Swipe through more Machine Learning concepts

Open Pocket Polymath