sir i am not getting how to calculate the no of times an alphabet occurs
sir can you plz give some hint
Strings-Max Frequency Character
u can simply make a 256 size int array
ie
freq[256] = {0} ;
since there are total of 256 ascii value
then iterate over the input string and
simple increment the value like
for(int i =0 ; i< s.size() ; i++){
freq[s[i]]+=1;
}
this will help u record the freq of each character