The code works but i'm not 100% certain on what a certain piece of the code does. To be exact the line of code "result += numbers[i]" I know the operator += and what result are doing there. "numbers" is also the "list" that the function is representing, but why the "[i]". If someone could explain that would be great having a hard time on how to read it.
n = [3, 5, 7] def total(numbers): result = 0 for i in range(len(numbers)): result += numbers[i] return result