s = input() ans = 0 l = 0 while l < len(s): if s[l] != '…': l += 1 continue r = l while r < len(s) and s[l] == s[r]: r += 1 ans = max(ans, r - l) l = r print(ans)