Question d’entretien chez Amazon

How does grep work internally?