X = input()
alpha, digit, space, other = 0, 0, 0, 0
for i in range(len(X)):
    a = ord(X[i])
    if a >= 65 and a <= 90:
        alpha += 1
    elif a >= 97 and a <= 122:
        alpha += 1
    elif a >= 48 and a <= 57:
        digit += 1
    elif a == 32:
        space += 1
    else:
        other += 1
print("alpha:", alpha)
print("digit:", digit)
print("space:", space)
print("other:", other)