Last active
October 12, 2015 23:08
-
-
Save c0ldlimit/4101461 to your computer and use it in GitHub Desktop.
Python: Stripping all whitespace #python #c0ldlimit #whitespace
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
s = " \t foo \n bar " | |
"".join(s.split()) | |
#http://stackoverflow.com/questions/3739909/how-to-strip-all-whitespace-from-string |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment