Software AG Interview Question

Given string aabbcdeee convert to a2b2cde3