#pragma GCC optimize("O3")
#include<bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
using vl = vector<ll>;
using vvl = vector<vector<ll>>;
using P = pair<ll,ll>;
using um = unordered_map<ll,ll>;
#define fl cout<<flush;
#define endl '\n'
template <typename T> inline void prt(T v){cout<<v<<'\n';}
template <typename T> inline bool chmax(T &a, const T &b){if (a<b){a=b;return 1;}return 0;}
template <typename T> inline bool chmin(T &a, const T &b){if (a>b){a=b;return 1;}return 0;}
const ll INF=1LL<<60;
const ll MOD=1e9+7;
const ll MOD2=998244353;
const ld pi=3.14159265358979323846;
const ld eps=1e-10;

#define debug(v) cout<<#v<<": ",prt(v);
template <typename A,typename B>
inline void prt(pair<A,B> p){cout<<"("<<p.first<<", "<<p.second<<")\n";}
template <typename A,typename B,typename C>
inline void prt(tuple<A,B,C> p){cout<<"("<<get<0>(p)<<", "<<get<1>(p)<<", "<<get<2>(p)<<")\n";}
inline void prt(bool p){if(p)cout<<"True"<<'\n';else cout<<"False"<<'\n';}
template <typename T> 
inline void prt(vector<T> v){cout<<'{';for(ll i=0;i<v.size();i++){cout<<v[i];if(i<v.size()-1)cout<<", ";}cout<<'}'<<'\n';}
template <typename T> 
inline void prt(deque<T> v){cout<<'{';for(ll i=0;i<v.size();i++){cout<<v[i];if(i<v.size()-1)cout<<", ";}cout<<'}'<<'\n';}
template <typename A,typename B>
inline void prt(map<A,B> v){cout<<'{';ll c=0;for(auto &p: v){cout<<p.first<<":"<<p.second;c++;if(c!=v.size())cout<<", ";}cout<<'}'<<'\n';}
template <typename A,typename B>
inline void prt(unordered_map<A,B> v){cout<<'{';ll c=0;for(auto &p: v){cout<<p.first<<":"<<p.second;c++;if(c!=v.size())cout<<", ";}cout<<'}'<<'\n';}
template <typename T> 
inline void prt(set<T> v){cout<<'{';for(auto i=v.begin();i!=v.end();i++){cout<<*i;if(i!=--v.end())cout<<", ";}cout<<'}'<<'\n';}
template <typename T> 
inline void prt(multiset<T> v){cout<<'{';for(auto i=v.begin();i!=v.end();i++){cout<<*i;if(i!=--v.end())cout<<", ";}cout<<'}'<<'\n';}

signed main(void){
    cin.tie(0);cout.tie(0);ios::sync_with_stdio(false);
    ll K;
    cin >> K;
    ll X;
    cin >> X;
    ll Y;
    cin >> Y;
    ll x=llabs(X);
    ll y=llabs(Y);
    ll M=(x+y)%K;
    if((x+y)%2==1&&K%2==0){
        prt(-1);
        return 0;
    }
    ll fx,fy;
    if(M!=0){
        if((K+M)%2==0){
            fy=(K+M)/2;
        }
        else {
            fy=M/2;
        }
        fx=fy-K;
    }
    deque<P> ans;
    if(M==0){
        fx=0,fy=0;
        if((x-fx)%K!=0)
        ans.emplace_back(P(fx+(x-fx)%K,fy+(y-fy)%K));
        fx+=(x-fx)%K,fy+=(y-fy)%K;
        while(fx!=x){ans.emplace_back(P(fx+K,fy));fx+=K;}
        while(fy!=y){ans.emplace_back(P(fx,fy+K));fy+=K;}
    }
    else if(fy>y&&fy<=x){
        swap(fx,fy);
        //fx=K-t,fy=-tになっとる
        ans.emplace_back(P(fx,fy));
        if((x-fx)%K!=0)
        ans.emplace_back(P(fx+(x-fx)%K,fy+(y-fy)%K));
        fx+=(x-fx)%K,fy+=(y-fy)%K;
        while(fx!=x){ans.emplace_back(P(fx+K,fy));fx+=K;}
        while(fy!=y){ans.emplace_back(P(fx,fy+K));fy+=K;}
    }
    //そのまま行ける場合
    else if(fy<=y){
        ans.emplace_back(P(fx,fy));
        if((x-fx)%K!=0)
        ans.emplace_back(P(fx+(x-fx)%K,fy+(y-fy)%K));
        fx+=(x-fx)%K,fy+=(y-fy)%K;
        while(fx!=x){ans.emplace_back(P(fx+K,fy));fx+=K;}
        while(fy!=y){ans.emplace_back(P(fx,fy+K));fy+=K;}
    }
    //考えなおす場合（2回でいける？？）
    else{
        if((K+M)%2==0&&llabs(x-((K+M)/2-K))+llabs(y-(K+M)/2)==K){
            ans.emplace_back(P((K+M)/2-K,(K+M)/2));
            ans.emplace_back(P(x,y));
        }
        else if(M%2==0&&llabs(x-(M/2-K))+llabs(y-M/2)==K){
            ans.emplace_back(P(M/2-K,M/2));
            ans.emplace_back(P(x,y));
        }
        else if((K+M)%2==0&&llabs(y-((K+M)/2-K))+llabs(x-(K+M)/2)==K){
            ans.emplace_back(P((K+M)/2,(K+M)/2-K));
            ans.emplace_back(P(x,y));
        }
        else if(M%2==0&&llabs(y-(M/2-K))+llabs(x-M/2)==K){
            ans.emplace_back(P(M/2,M/2-K));
            ans.emplace_back(P(x,y));
        }
        else {
            ans.emplace_back(P(fx,fy));
            ans.emplace_back(P(fx,fy-K));
            fy-=K;
            if((x-fx)%K!=0)
            ans.emplace_back(P(fx+(x-fx)%K,fy+(y-fy)%K));
            fx+=(x-fx)%K,fy+=(y-fy)%K;
            while(fx!=x){ans.emplace_back(P(fx+K,fy));fx+=K;}
            while(fy!=y){ans.emplace_back(P(fx,fy+K));fy+=K;}
        }
        
    }
    ll A=1,B=1;
    if(X!=x)A=-1;
    if(Y!=y)B=-1;
    prt(ans.size());
    for(auto p: ans){
        cout<<p.first*A<<" "<<p.second*B<<endl;
    }fl

    
    return 0;
}



Measured memory_bytes: 6524