From f97e114a5976098e464068b389a25e65030c9387 Mon Sep 17 00:00:00 2001 From: caelmeasnadh Date: Sun, 6 Aug 2023 21:39:10 +0300 Subject: [PATCH] my version --- IsitAPalindrome.py | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/IsitAPalindrome.py b/IsitAPalindrome.py index 02c9aef..bfd5187 100644 --- a/IsitAPalindrome.py +++ b/IsitAPalindrome.py @@ -1,6 +1,2 @@ def is_palindrome(s): - s = list(s.lower()) - if s == s[::-1]: - return True - else: - return False \ No newline at end of file + return s.lower() == s.lower()[::-1] \ No newline at end of file