Garmin interview question

Tell me what this code does. Simply did pointer manipulation on a string to iterate over the string and count the occurrences of each character