k=int(input())
x,y=map(int,input().split())
d=abs(x)+abs(y)
if k%2==0 and d%2!=0:
  print(-1)
else:
  ans=[]
  if d<k and d%2==1:
    n=3
    td=k-d
    if y>=0:
      ans.append((x,y+td))
      ans.append((x+(k-td//2),y+td//2))
      ans.append((x,y))
    else:
      ans.append((x,y-td))
      ans.append((x+(k-td//2),y-td//2))
      ans.append((x,y))
  elif d<k and d%2==0:
    n=2
    if abs(x)>=abs(y):
      m=(abs(x)-abs(y))//2
      tk=k-m
      if x<0:
        m*=-1
      if y<0:
        tk*=-1
      ans.append((m,tk))
    else:
      m=(abs(y)-abs(x))//2
      tk=k-m
      if y<0:
        m*=-1
      if x<0:
        tk*=-1
      ans.append((tk,m))
    ans.append((x,y))
  tg=max(abs(x),abs(y))
  ts=k-min(abs(x),abs(y))%k
  elif tg-ts<k and (tg-ts)%2!=0:
    ans.append((1,1))
  else:
    n=0
    ans.append((0,0))
    if abs(x)<=abs(y):
      n+=abs(x)//k
      for i in range(abs(x)//k):
        if x>=0:
          ans.append((ans[-1][0]+k,0))
        else:
          ans.append((ans[-1][0]-k,0))
      if ans[-1][0]!=x:
        n+=1
        if y>=0:
          ans.append((x,k-abs(x-ans[-1][0])))
        else:
          ans.append((x,-(k-abs(x-ans[-1][0]))))
      td=abs(y-ans[-1][1])
      if td%k==0:
        flag=True
      else:
        flag=False
      for i in range(td//k):
        if flag==False and abs(y-ans[-1][1])%2==0 and abs(y-ans[-1][1])<=2*k:
          break
        else:
          n+=1
          if y>=0:
            ans.append((x,ans[-1][1]+k))
          else:
            ans.append((x,ans[-1][1]-k))
      if ans[-1][1]!=y:
        n+=2
        td=abs(y-ans[-1][1])
        if y>=0:
          ans.append((x+(k-td//2),ans[-1][1]+td//2))
          ans.append((x,y))
        else:
          ans.append((x+(k-td//2),ans[-1][1]-td//2))
          ans.append((x,y))
    else:
      n+=abs(y)//k
      for i in range(abs(y)//k):
        if y>=0:
          ans.append((0,ans[-1][1]+k))
        else:
          ans.append((0,ans[-1][1]-k))
      if ans[-1][1]!=y:
        n+=1
        if x>=0:
          ans.append((k-abs(y-ans[-1][1]),y))
        else:
          ans.append((-(k-abs(y-ans[-1][1])),y))
      td=abs(x-ans[-1][0])
      if td%k==0:
        flag=True
      else:
        flag=False
      for i in range(td//k):
        if flag==False and abs(x-ans[-1][0])%2==0 and abs(x-ans[-1][0])<=2*k:
          break
        else:
          n+=1
          if x>=0:
            ans.append((ans[-1][0]+k,y))
          else:
            ans.append((ans[-1][0]-k,y))
      if ans[-1][0]!=x:
        n+=2
        td=abs(x-ans[-1][0])
        if x>=0:
          ans.append((ans[-1][0]+td//2,y+(k-td//2)))
          ans.append((x,y))
        else:
          ans.append((ans[-1][0]-td//2,y+(k-td//2)))
          ans.append((x,y))
    ans.pop(0)
  print(n)
  for tx,ty in ans:
    print(tx,ty)

### FIXED CODE ###

def editarr(x,y,arr):
  if abs(x)>=abs(y):
    for i in range(len(arr)):
      arr[i][0],arr[i][1]=arr[i][1],arr[i][0]
  if x<0:
    for i in range(len(arr)):
      arr[i][0]*=-1
  if y<0:
    for i in range(len(arr)):
      arr[i][1]*=-1

k=int(input())
x,y=map(int,input().split())
ans=[]
tx=abs(x)
ty=abs(y)
if tx>=ty:
  tx,ty=ty,tx
if k%2==0 and (tx+ty)%2!=0:
  print(-1)
else:
  if tx+ty<k:
    if (tx+ty)%2==0:
      m=(ty-tx)//2
      ans.append([k-m,m])
    else:
      td=k-(tx+ty)
      ans.append([tx,ty+td])
      ans.append([tx+(k-td//2),ty+td//2])
    ans.append([tx,ty])
    n=len(ans)
  elif ty-(k-tx%k)<k and (ty-(k-tx%k))%2!=0:
    if tx<k and ty<k:
      if (2*k-(tx+ty))%2==0:
        td=2*k-(tx+ty)
        ans.append([tx+td//2,k-(tx+td//2)])
        ans.append([tx,ty])
      else:
        ans.append([tx,k-tx])
        td=ty-(k-tx)
        ans.append([tx+(k-td//2),ans[-1][1]+td//2])
        ans.append([tx,ty])
      n=len(ans)
    else:
      if tx+ty<2*k:
        if (2*k-(tx+ty))%2==0:
          td=2*k-(tx+ty)
          ans.append([tx+td//2,k-(tx+td//2)])
          ans.append([tx,ty])
        else:
          ans.append([tx,k-tx])
          td=ty-(k-tx)
          ans.append([tx+(k-td//2),ans[-1][1]+td//2])
          ans.append([tx,ty])
        n=len(ans)
      else:
        ans.append([0,0])  
  else:
    ans.append([0,0])
    for i in range(tx//k):
      ans.append([ans[-1][0]+k,0])
    if ans[-1][0]!=tx:
      ans.append([tx,k-abs(tx-ans[-1][0])])
    td=ty-ans[-1][1]
    if td%k==0:
      flag=True
    else:
      flag=False
    for i in range(td//k):
      if flag==False and (ty-ans[-1][1])%2==0 and (ty-ans[-1][1])<=2*k:
          break
      ans.append([tx,ans[-1][1]+k])
    if ans[-1][1]!=ty:
      td=ty-ans[-1][1]
      ans.append([tx+(k-td//2),ans[-1][1]+td//2])
      ans.append([tx,ty])
    ans.pop(0)
    n=len(ans)
  editarr(x,y,ans)
  print(n)
  for a,b in ans:
    print(a,b)