char s[1010];m,M,i,c;main(n){for(n=strlen(gets(s));c+=m>=i&m-i