Software AG interview question

Given string aabbcdeee convert to a2b2cde3