We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent de5164c commit 66335b3Copy full SHA for 66335b3
valid-palindrome/devyejin.py
@@ -1,6 +1,5 @@
1
# isalnum() : 문자열이 영어, 한글 숫자 -> True , 아니라면 False
2
class Solution:
3
def isPalindrome(self, s: str) -> bool:
4
- s = s.replace(" ", "")
5
changed_s = [c.lower() for c in s if c.isalnum()]
6
return changed_s == changed_s[::-1]
0 commit comments