S, last = list(input().split('#')) if S == '': print('0 0') len_S = len(S) right = 0 left = 0 for i in range(0, len_S, 5): if S[i+1] == '*': right += 1 else: left += 1 print('{0} {1}'.format(left, right))