ll@n,@m,@a[n],s=0;mapc;c[a[0..n-1]%=m]++;rep[a](e,n)s+=2e%m?(c[e]>?=c[m-e]):!!c[e],c[e]=c[m-e]=0;wt(s);