d=r=c=p=0 for y in [*open(0)][1]:c=1+c*(x:=int(y)-p==d);r+=c>=r;d=x-p;p=x print(r)