Function to return the required count
static int countMinParts ( String str ) { int n = str . Length ; int [ ] freq = getFrequencies ( str ) ; List < int > oddFreq = new List < int > ( ) ; List < int > evenFreq = new List < int > ( ) ; int i , sumEven = 0 ; for ( i = 0 ; i < 26 ; i ++ ) { if ( freq [ i ] == 0 ) continue ;