Question d’entretien chez Niantic

Counting squares, debug this piece of code.