Question d’entretien chez Apple

Given a 2-D array, find the average of a sub-array