Valid Palindrome
A phrase is a palindrome if, after converting all uppercase letters into lowercase letters and removing all non-alphanumeric characters, it reads the same forward and backward.

30:00

Valid Palindrome
easy
Topics
Companies

A phrase is a palindrome if, after converting all uppercase letters into lowercase letters and removing all non-alphanumeric characters, it reads the same forward and backward.

Example 1:
Input: "A man, a plan, a canal: Panama"
Output: true
Constraints:
  • 1s.length2×1051 \leq s.\text{length} \leq 2 \times 10^5

  • s consists only of printable ASCII characters.

Input
arr ="A man, a plan, a canal: Panama"
Comparing characters...
A

L

m
a
n
,
a
p
l
a
n
,
a
c
a
n
a
l
:
P
a
n
a
m
a

R

Variables
VariableValue
l0
r29
DepthFunction Call
Stack empty
0/54