Count frequency of consecutive letters
Filed under Mastercard
The question
Given a string like 'aaabbcdddd', return 'a3b2c1d4'.
No write-up yet. Related questions below have one.
Related Mastercard questions
Collected from public candidate posts and coding forums. Updated Nov 2026.