Skip to content

Instantly share code, notes, and snippets.

@looopTools
Created March 29, 2016 20:37
Show Gist options
  • Save looopTools/aa99d0dc629a401afb75eca2d219c974 to your computer and use it in GitHub Desktop.
Save looopTools/aa99d0dc629a401afb75eca2d219c974 to your computer and use it in GitHub Desktop.
def even_palindrom(x):
left = 0
right = len(x) - 1
while(left != right):
print("left: {}".format(left))
print("right: {}".format(right))
if not x[left] == x[right]:
return False
else:
left = left + 1
right = right - 1
return True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment