Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

strip all elements in list python

# 
my_list = ['one ', ' tow', 'three']
my_list = list(map(str.strip, my_list))
print(my_list) # ['one', 'tow', 'three']
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #strip #elements #list #python
ADD COMMENT
Topic
Name
9+2 =