We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
// Complete the gameOfThrones function below.staticStringgameOfThrones(Strings){Stringa="abcdefghijklmnopqrstuvwxyz";intoc=0,ec=0;intl=s.length();for(inti=0;i<26;i++){intc=0;for(intj=0;j<l;j++){if(a.charAt(i)==s.charAt(j))c++;}if(c%2==0)ec++;elseoc++;}if(oc<=1)return"YES";elseif(oc==2&&l%2==0)return"YES";elsereturn"NO";}
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Game of Thrones - I
You are viewing a single comment's thread. Return to all comments →
Best Solution in Java to pass all the testcases