#K10. Palindromic Rearrangement
Palindromic Rearrangement
Palindromic Rearrangement
You are given a string s consisting of only lowercase English letters. Your task is to determine whether its characters can be rearranged to form a palindrome.
A string is a palindrome if it reads the same backward as forward. A necessary and sufficient condition for the rearrangement to form a palindrome is that the number of characters with an odd frequency is at most one, i.e. \( \leq 1 \).
The input is provided via standard input (stdin) as a single line, and you should output a single line to standard output (stdout) with "YES" if a palindromic rearrangement is possible or "NO" otherwise.
inputFormat
The input consists of a single line containing the string s which only includes lowercase English letters.
outputFormat
Output a single line with either "YES" or "NO" (without quotes) based on whether it is possible to rearrange the characters of s to form a palindrome.
## samplecivic
YES