C# Palindrome Rearranging
static bool PalindromeRearranging(string inputString)
{
var counts = new Dictionary<char, int>();
foreach (var ch in inputString)
{
counts[ch] = counts.GetValueOrDefault(ch) + 1;
}
var oddCount = counts.Values.Count(v => v % 2 != 0);
return oddCount <= 1;
}
This counts character frequency and checks whether the string has the right number of odd counts to form a palindrome.