s=str(input()) n=len(s) t=200 if 33<=len(s): t=400 for x in range(n): if ord(s[x])==45 or ord(s[x])==95 or 65<=ord(s[x])<=95 or 97<=ord(s[x])<=122: 0 else: t=400 if ord(s[0])==45 or ord(s[0])==95: t=400 if ord(s[-1])==45 or ord(s[-1])==95: t=400 print(t)