S=input() ANS=0 for i in range(len(S)): for j in range(i,len(S)+1): T=S[i:j] if T==T[::-1] and len(T)