Count of consonents
long cnt_cnst = 0 ; for ( Map . Entry < Character , Integer > itr : freq . entrySet ( ) ) { if ( ! isVowel ( itr . getKey ( ) ) ) { denom *= fact ( itr . getValue ( ) ) ; cnt_cnst += itr . getValue ( ) ; } }