0

nums = [7, 7, 7, 7, 7] nums[2] = 5 print(nums)

How I don't know

27th Oct 2019, 7:15 AM
Mg Thiha Ye
Mg Thiha Ye - avatar
5 Réponses
+ 11
Thiha yehtut Please, Can you specifying your question correctly! • Include relevant TAGS; and • Use the 🔍SEARCH... bar future for similar QUESTIONS or ANSWERS before posting.
27th Oct 2019, 8:11 AM
Danijel Ivanović
Danijel Ivanović - avatar
+ 9
num[2] = 5 replaces the second element 7 (counting from zero) from the list with 5
27th Oct 2019, 7:20 AM
VEDANG
VEDANG - avatar
+ 3
The index of an array starts from 0. Then nums [2] is the third number in the array. So the final array will be: [7,7,5,7,7]
27th Oct 2019, 7:22 AM
Eliya Ben Baruch
Eliya Ben Baruch - avatar
+ 1
What are you trying to understand?
27th Oct 2019, 7:20 AM
Eliya Ben Baruch
Eliya Ben Baruch - avatar