S = input() i = 0 left = 0 right = 0 while True: if S[i] == '#': break if S[i + 1] == '*': right += 1 else: left += 1 i += 5 print(left, right)