Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

Remove an element from a Python list Using pop() method

List = [1,2,3,4,5]
 
# Removing element from the
# Set using the pop() method
List.pop()
print("
List after popping an element: ")
print(List)
 
# Removing element at a
# specific location from the
# Set using the pop() method
List.pop(1)
print("
List after popping a specific element: ")
print(List)
Source by softhunt.net #
 
PREVIOUS NEXT
Tagged: #Remove #element #Python #list #Using #method
ADD COMMENT
Topic
Name
9+9 =