#include <bits/stdc++.h>

using namespace std;

#define vec vector
#define ALL(x) (x).begin(), (x).end()

typedef unsigned int ui;
typedef long long ll;
typedef long double ld;
typedef pair< int, int > pii;
typedef pair< long long, long long > pll;

const int inf = 1e9;
const ll inf64 = 1e18;

inline int get_max(const vec< int >& f, int p) {
    int r = 0;
    for(int cur = p;cur >= 0;cur = (cur & (cur + 1)) - 1) {
        r = max(r, f[cur]);
    }
    return r;
}

inline void upd(vec< int >& f, int p, int x) {
    for(int cur = p;cur < (int)f.size();cur |= (cur + 1)) {
        f[cur] = max(f[cur], x);
    }
}

int inc(const vec< int >& a) {
    int n = (int)a.size();
    vec< int > f(n + 1, 0);
    int r = 0;
    for(int i = 0;i < n;i++) {
        int x = get_max(f, a[i] - 1) + 1;
        r = max(r, x);
        upd(f, a[i], x);
    }
    return r;
}

bool check(int n, int a, int b, vec< int > p) {
    if((int)p.size() != n) {
        return false;
    }
    {
        vec< int > ar = p;
        sort(ALL(ar));
        ar.resize(unique(ALL(ar)) - ar.begin());
        if((int)ar.size() != n) {
            return false;
        }
        if(ar.front() < 1 || ar.back() > n) {
            return false;
        }
    }
    vec< int > p2 = p;
    for(int i = 0;i < n;i++) {
        p2[i] = n + 1 - p2[i];
    }
    if(inc(p) == a && inc(p2) == b) {
        return true;
    }
    return false;
}

bool brute(int n, int a, int b, vec< int >& res) {
    vec< int > p(n);
    for(int i = 0;i < n;i++) {
        p[i] = i + 1;
    }
    do {
        vec< int > p2 = p;
        for(int i = 0;i < n;i++) {
            p2[i] = n + 1 - p2[i];
        }
        if(inc(p) == a && inc(p2) == b) {
            res = p;
            return true;
        }
    }while(next_permutation(ALL(p)));
    return false;
}

bool solve(int n, int a, int b, vec< int >& res) {
    if(a + b - 1 > n) {
        return false;
    }
    if(a == 1) {
        if(b == 1) {
            if(n == 1) {
                res = {1};
                return true;
            }else {
                return false;
            }
        }else {
            if(b == n) {
                res.clear();
                for(int i = n;i >= 1;i--) {
                    res.push_back(i);
                }
                return true;
            }else {
                return false;
            }
        }
    }
    if(b == 1) {
        if(a == 1) {
            if(n == 1) {
                res = {1};
                return true;
            }else {
                return false;
            }
        }else {
            if(a == n) {
                res.clear();
                for(int i = 1;i <= n;i++) {
                    res.push_back(i);
                }
                return true;
            }else {
                return false;
            }
        }
    }

    int flag = 0;

    if(a < b) {
        swap(a, b);
        flag = 1;
    }

    if(a <= 3) {
        if(n > 9) {
            return false;
        }
        if(!brute(n, a, b, res)) {
            return false;
        }
        if(flag) {
            for(int& x : res) x = n + 1 - x;
        }
        return true;
    }

//    if(a + 1ll * a * b < n) {
//        return false;
//    }

    int cnt = n / (1ll * a * (b + 1));

    res.clear();

    int big = n;

    for(int it = 0;it < cnt;it++) {
        int low = big - 1ll * b * (a + 1) + 1;
        for(int i = 0;i < a;i++) {
            for(int x = low + b - 1;x >= low;x--) {
                res.push_back(x);
            }
            low += b;
        }
        big -= 1ll * b * (a + 1);
    }

    int empt = n - (int)res.size() - a;

    if(empt < 0) {
        for(int i = 1;i <= n - (int)res.size();i++) {
            res.push_back(i);
        }
        return true;
    }

    int last = 0;

    for(int i = 1;i <= a;i++) {
        int ad = min(empt, b - 1);
        empt -= ad;
        ad++;
        for(int x = last + ad;x > last;x--) {
            res.push_back(x);
        }
        last += ad;
    }

    if(flag) {
        for(int& x : res) x = n + 1 - x;
    }

    return true;
}

bool random_solve(int n, int a, int b, vec< int >& res) {
    vec< int > p(n);
    for(int i = 0;i < n;i++) {
        p[i] = i + 1;
    }
    const double MAX_TIME = 1.89 * CLOCKS_PER_SEC;
    while(clock() < MAX_TIME) {
        vec< int > p2 = p;
        for(int i = 0;i < n;i++) {
            p2[i] = n + 1 - p2[i];
        }
        if(inc(p) == a && inc(p2) == b) {
            res = p;
            return true;
        }
    };
    return false;
}

void stress() {
    srand(42);

    while(1) {
        vec< int > p, h;
        int n, a, b;

        n = rand() % 10000 + 1;

        for(int i = 0;i < n;i++) {
            p.push_back(i + 1);
        }
        random_shuffle(ALL(p));
        h = p;
        {
            a = inc(p);
        }

        {
            vec< int > p2 = p;
            for(int& x : p2) {
                x = n + 1 - x;
            }
            b = inc(p2);
        }

        cout << n << " " << a << " " << b << " : ";

        p.clear();
        if(solve(n, a, b, p)) {
            if(!check(n, a, b, p)) {
                cout << "WA " << n << " " << a << " " << b << "\n";
                for(int x : h) {
                    cout << x << " ";
                }
                cout << "\n";
                return;
            }else {
                cout << "OK\n";
            }
//            for(int x : p) {
//                cout << x << " ";
//            }
//            cout << "\n";
        }else {
            cout << "WA " << n << " " << a << " " << b << "\n";
            for(int x : h) {
                cout << x << " ";
            }
            cout << "\n";
            return;
        }

        {
            cout << "inc = " << inc(p) << ", ";
            for(int& x : p) {
                x = n + 1 - x;
            }
            cout << "dec = " << inc(p) << "\n";
        }
    }
}

int sl() {
    vec< int > p;
    int n, a, b;

    cin >> n >> a >> b;

    p.clear();
    if((n > 9 ? solve(n, a, b, p) : brute(n, a, b, p))) {
        if(check(n, a, b, p)) {
            for(int x : p) {
                cout << x << " ";
            }
            cout << "\n";
        }else {
            cout << "-1\n";
        }
    }else {
        cout << "-1\n";
    }

    return 0;
}

int main() {

#ifdef debug
    freopen("input.txt", "r", stdin);
#endif

//    stress();
    sl();

    return 0;
}


Measured memory_bytes: 4956