[Solved] Can this [0] mean the whole list?


N1 is simply just a list of names (that are of type String).

When you loop / iterate over your list (for names in N1), each loop iteration will then act on that index of the list. So for the first iteration of the loop, names is equal to Ryan and therefore since you are accessing the 0th index of a string (the first character), names[0] is equal to R and names[2] is equal to a.

Hope that helps!

1

solved Can this [0] mean the whole list?