Advertisement
here2share

# remove_empties.py

Oct 6th, 2016
194
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.17 KB | None | 0 0
  1. # remove_empties.py
  2.  
  3. # note: will also remove the zero values
  4. z=25
  5. test=['',123,0,"",None,9,' ',False,'abc','',z,True,False,123,'0']
  6.  
  7. result=filter(None, test)
  8. print result
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement