Answers for "del and remove in python"

2

how to delete in python

#x will be deleted
print("xb")
Posted by: Guest on March-10-2021
2

del vs remove python

A = [1,2,3,4]
del(A[1])
# A: [1,3,4]
B = {9,8,7,6}
B.remove("8")
# B: {9,7,6}
Posted by: Guest on May-31-2020

Python Answers by Framework

Browse Popular Code Answers by Language