package main import . "fmt" const X=5e17 func abs(a int64) int64 { if a<0 { return -a } return a } func max(a,b int64) int64 { if a0 { u=append(u,1) v=append(v,t+1) aa:=(a[0]+a[t])/2 bb:=(b[0]+b[t])/2 a[0],b[0]=aa,bb a[t],b[t]=aa,bb } } Println(len(u)) for i,e:=range u { Println(e,v[i]) } }