import re

S = eval(input())

H = re.findall("[ACGT]+", S)

max_length = 0

for h in H:

	if max_length < len(h):

		max_length = len(h)

print(max_length)

import re

H = re.findall("[ACGT]+", eval(input()))

print((len(max(H, key=lambda x: len(x))) if H else 0))

import re

S = eval(input())
H = re.findall("[ACGT]+", S)
max_length = 0
for h in H:
    if max_length < len(h):
        max_length = len(h)
print(max_length)

import re

H = re.findall("[ACGT]+", eval(input()))
print((len(max(H, key=lambda x: len(x))) if H else 0))

-S = eval(input()) -H = re.findall("[ACGT]+", S) -max_length = 0 -for h in H: -    if max_length < len(h): -        max_length = len(h) -print(max_length) +H = re.findall("[ACGT]+", eval(input())) +print((len(max(H, key=lambda x: len(x))) if H else 0))