Last active
March 26, 2017 12:34
-
-
Save mrahul17/3857960c88df16da8934b50da307ffe3 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# Normalize strings having various forms of whitespace | |
" ".join(s.split()) | |
# Ternary Operator | |
(1 and [a] or [b])[0] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment