import java.util.*;
public class StringCharNumberDemo {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String strings = scanner.next();
char[] chars = strings.toCharArray();
LinkedHashMap<Character,Integer> hashMap = new LinkedHashMap<>();
for (char aChar : chars) {
if (!hashMap.containsKey(aChar)) {
hashMap.put(aChar, 1);
} else {
hashMap.put(aChar, hashMap.get(aChar) + 1);
}
}
Set<Map.Entry<Character, Integer>> entries = hashMap.entrySet();
for (Map.Entry<Character, Integer> next : entries) {
System.out.println(next);
}
}
}