#K81872. Rearrange to Palindrome

    ID: 35850 Type: Default 1000ms 256MiB

Rearrange to Palindrome

Rearrange to Palindrome

You are given a string s. Your task is to determine whether the characters of s can be rearranged to form a palindrome.

A palindrome is a string that reads the same backward as forward. A necessary and sufficient condition for a string to be rearranged into a palindrome is that at most one character appears an odd number of times. In mathematical terms, let \( f(c) \) be the frequency of character \( c \) in \( s \), then the string can form a palindrome if and only if:

\( \sum_{c}(f(c)\bmod2) \le 1 \)

Determine whether this condition is satisfied for the given string.

inputFormat

The input consists of a single line containing the string s. The string may include both uppercase and lowercase letters.

outputFormat

Output True if the string can be rearranged into a palindrome, otherwise output False.

## sample
aabb
True

</p>