#C12371. Palindrome Checker

    ID: 41791 Type: Default 1000ms 256MiB

Palindrome Checker

Palindrome Checker

Your task is to determine whether a given string is a palindrome. A string is considered a palindrome if it reads the same backwards as forwards after removing all non-alphanumeric characters and ignoring case. Mathematically, for a string \( S = s_1 s_2 \dots s_N \), the string is a palindrome if for all \( i \) (\( 1 \leq i \leq N \)) it holds that \( s_i = s_{N-i+1} \).

The string may contain spaces, punctuation, and other special characters which should be ignored. Only letters (\( a \) to \( z \), regardless of case) and digits (\( 0 \) to \( 9 \)) are considered in determining whether the string is a palindrome.

inputFormat

The input consists of a single line containing a string \( s \). This string can include letters, digits, spaces, and punctuation symbols.

outputFormat

Output a single line. Print True if the string is a palindrome under the specified criteria and False otherwise.

## sample
A man, a plan, a canal, Panama
True