R=range O=print N=int(input()) a=[] def P(T): global D,a if len(T)^1:D+=[(d,T[d::2])for d in R(2)] else:a+=[(i,T[0])] for i in R(1,N+1): D=[(0,list(R(i+1,N+1)))] while D: b,T=D.pop() if T: O("?",1,len(T),i,*T,flush=1) if input()=="1":P(T) elif b:P(D.pop()[1]) O("!",len(a)) for e in a:O(*e)