from collections import Counter c = Counter(list(input())) print(c["Y"], c["E"], c["A"], c["H"], c["!"])