0
why there is pop(), remove(), but no del()?
I mean why you have to say del list[0] rather than list.del(0) ? thanks
2 Answers
+ 11
del is more universal and type-independent. It deletes any variable not just a list-type. Whilst pop() and remove() are list-bound methods.
+ 1
It's programmer friendly