- 1

If list is zero indexed, what is the output of printing out list[3] if list = [343 , 22, 50, 25, 100]?

If list is zero indexed, what is the output of printing out list[3] if list = [343 , 22, 50, 25, 100]?

30th Apr 2018, 2:23 PM
shadrach esharive
shadrach esharive - avatar
1 Réponse
+ 4
I'm assuming this is for Python? You shouldn't use the identifier name list as it will shadow the built in type name list. l = [343, 22, 50, 25, 100] print(l[3]) will output 25
30th Apr 2018, 2:35 PM
ChaoticDawg
ChaoticDawg - avatar