Question d’entretien chez Google

Backtracking question with array sums.