ll n,k,j,t,z;char s[51];{rd(n,k,s);rep(i,k)t?--t:++z,t+=s[j++]-48,j*=j