Changing specific values in a list (why one method works and the other does not?)

前端 未结 0 851
野性不改
野性不改 2020-12-04 03:15

If I have a list:

list = [1, 1, 2, 3, 4, 4, 5]

and I want to change, say all 4\'s to \'None\' like so:

list = [1, 1, 2, 3, Non         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题