Sony Interview Question

Given a string ("aaaabbbccc") print out how many times each character appears in the string.