Skip to content

Instantly share code, notes, and snippets.

@samuelbalogh
Last active October 31, 2016 14:06
Show Gist options
  • Save samuelbalogh/9674d836bbd1c3fcd69df504d3e9c4bb to your computer and use it in GitHub Desktop.
Save samuelbalogh/9674d836bbd1c3fcd69df504d3e9c4bb to your computer and use it in GitHub Desktop.
Returns true if argument is a palindrome.
def isPal(s):
reverse = s[::-1]
return s == reverse
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment