FARFETCH Interview Question

small exercise to correct a for loop