Skip to content

Instantly share code, notes, and snippets.

@opethe1st
Created April 13, 2017 16:45
Show Gist options
  • Save opethe1st/0856dd646647910431dad319d2c6b044 to your computer and use it in GitHub Desktop.
Save opethe1st/0856dd646647910431dad319d2c6b044 to your computer and use it in GitHub Desktop.
def flip(s):
res = []
for l in s:
if l=='+':
res.append('-')
else:
res.append('+')
return "".join(res)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment