0

List Pop method

nums = [1, 2, 3, 4, 5] nums. pop(0) So running this is giving me an output [3, 4, 5] but it should be [2, 3, 4, 5]? Since at index 0 there is 1

26th Jul 2021, 6:41 AM
Dipanjan Basu
Dipanjan Basu - avatar
2 Réponses
+ 3
My output is [2,3,4,5] are you sure of your output?
26th Jul 2021, 6:49 AM
Baribor Saturday
Baribor Saturday - avatar
+ 1
Got the same output now. Thanks!
26th Jul 2021, 7:43 AM
Dipanjan Basu
Dipanjan Basu - avatar