Palindrome row#5911

Palindrome row

0.5 seconds
256 megabytes
Easy

Ksyusha has a string and she enjoys rearranging its letters. She is curious to find out how many distinct palindromes she can create by rearranging the letters of .

A palindrome is a string that reads the same forwards and backwards. For example, the string "ded" is a palindrome.

Input

The input consists of a single line containing the string , where

1 \leq |s| \leq 20

and consists only of lowercase Latin letters.

Output

Output a single integer representing the number of unique palindromes Ksyusha can form by rearranging the letters of the string .

Examples

Example 1

Loading
Loading

Note

A string x = x_1x_2\ldots x_p is considered lexicographically smaller than a string y = y_1y_2\ldots y_q if either p < q and x_1 = y_1, x_2 = y_2, ..., x_p = y_p, or there exists an index (r < p, r < q) such that x_1 = y_1, x_2 = y_2, ..., x_r = y_r and x_{r+1} < y_{r+1}. The characters of the strings are compared according to their ASCII values.