Page 1 of 1

Display string in correct format

Posted: Tue Dec 02, 2014 8:35 am
by Rakesh123
Hi Frnds,
I have a small scenario..
For e.g:If i pass a string as "aabbbcccc".O/P should be 2a3b4c
If i pass a string as "ddeefdffss".O/P should be 3d2e3f2s
Can anyone tell me the logic for this?
Thanks,
Rakesh