A phrase is a palindrome if, after converting all uppercase letters to lowercase and removing every character that is not a letter or digit, it reads the same forwards and backwards.
Given a string s, return true if it is a palindrome.
Example 1
Input: s = "A man, a plan, a canal: Panama"
Output: true
Explanation: "amanaplanacanalpanama" is a palindrome.
Example 2
Input: s = "race a car"
Output: false
Constraints
1 <= s.length <= 200000s consists of printable ASCII characters.Input
s = "A man, a plan, a canal: Panama"
Expected
true
5 hidden tests run on submit