using System;
using System.Collections;
public class Program
{
public static void Main()
string str = "SACSACC";
while (str.Length > 0)
Console.Write(str[0]);
int cal = 0;
for (int j = 0; j < str.Length; j++) {
if (str[0] == str[j]) {
cal++;
}
Console.Write(cal);
str = str.Replace(str[0].ToString(), string.Empty);
/* Hashtable ht = new Hashtable();
for (int i = 0; i < str.Length; i++) {
ht.Add(i,str[i]);
int count =0 ;
foreach(DictionaryEntry de in ht)
if(ht.ContainsValue(de.Value))
count++;
Console.WriteLine(de.Value.ToString()+count);
}*/
// Console.Write(ht.ContainsValue(a)+":"+count);