Why do cows wear bells?

Why do cows wear bells?