Nitesh kumar

Nitesh kumar

  • NA
  • 45
  • 566

Count character from string.

Apr 24 2017 2:22 AM
Hi,
I want to write the program How to count the repeted character from the string and print each charater count value.
 
Ex. I have
  string str="asfsdfyagfdvgbf";
 
and i want to output in the below format.
 
 a=2
 s=2
 f=4
 d=2  ...  and so on.
 
 
Thanks 

Answers (3)