From 9e325f974be300da49c3475ab6a366d461b64844 Mon Sep 17 00:00:00 2001 From: Oluwatomi01 <78262830+Oluwatomi01@users.noreply.github.com> Date: Thu, 4 Feb 2021 22:31:06 +0100 Subject: [PATCH] sca project --- src/app.py | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/app.py b/src/app.py index 7ffdd66..aba211e 100644 --- a/src/app.py +++ b/src/app.py @@ -4,7 +4,20 @@ def palindrome(s): # your code goes here - + source = [] + for letter in s: + letter = letter.strip() + letter = letter.lower() + if len(letter) <= 0: + continue + source.append(letter) + account = (len(source) - 1) + for entry in source: + if entry == source[account]: + account -= 1 + continue + if account == -1: + print(s) def solution(s): return palindrome(s)