const NMax=2000000000; var M,N,i,j,k,D:integer; input,output:text; S:array[1..Nmax] of integer; b:array[1..Nmax] of integer; begin assign (input,'poblem.in'); reset(input); read(input,N,M); assign (output,'in problem.out'); rewrite(output); writeln(output,K); K:=0; B[1]:=1; S[1]:=0; for i:=2 to N do S[i]:=S[i-1]+B; B[i]:=B[i-1]+1; if D:=S/N integer then K:=K+1; close(input); close(output); en