Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

challenge python 01 commit added by pachom #86

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,23 @@


def is_palindrome(palindrome):
# Start coding here
pass
"""
validates that the string palindrome is a
palindrome (it is a word or phrase that
read equal to right and back

param str palindrome is a word or Phrase

returns True if the word or phrase is a
palindorme or False if not.
"""

reversed_letters = palindrome[::-1]

if reversed_letters.lower().replace(' ','') == palindrome.lower().replace(' ',''):
return True
else:
return False

def validate():
for palindrome in PALINDROMES:
Expand Down