#include <iostream>
using namespace std;
const int MAX_SIZE = 10;
int main() {
int size, oddLinesNum, evenLinesNum;
cin >> size >> oddLinesNum >> evenLinesNum;
int mt[MAX_SIZE + 1][MAX_SIZE + 1], oddCurrentEl = 0, evenCurrentEl = 0, number = 1;
for (int line = 1; line <= size; ++line) {
number *= -1;
for (int col = 1; col <= size; ++col) {
/*
if (line % 2) {
//mt[line][col] = col * oddLinesNum;
//cout << (mt[line][col] = col * oddLinesNum) << " ";
cout << col * oddLinesNum << " ";
} else {
//mt[line][col] = (size - (col - 1)) * evenLinesNum;
//cout << (mt[line][col] = (size - (col - 1)) * evenLinesNum) << " ";
cout << (size - (col - 1)) * evenLinesNum << " ";
}
//cout << mt[line][col] <<" ";
*/
oddCurrentEl = line % 2 * col * oddLinesNum;
evenCurrentEl = (line % 2 + number) * (size - (col - 1)) * evenLinesNum;
mt[line][col] = oddCurrentEl + evenCurrentEl;
cout << mt[line][col] << " ";
}
cout << "\n";
}
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKY29uc3QgaW50IE1BWF9TSVpFID0gMTA7CgppbnQgbWFpbigpIHsKICAgIGludCBzaXplLCBvZGRMaW5lc051bSwgZXZlbkxpbmVzTnVtOwogICAgY2luID4+IHNpemUgPj4gb2RkTGluZXNOdW0gPj4gZXZlbkxpbmVzTnVtOwogICAgaW50IG10W01BWF9TSVpFICsgMV1bTUFYX1NJWkUgKyAxXSwgb2RkQ3VycmVudEVsID0gMCwgZXZlbkN1cnJlbnRFbCA9IDAsIG51bWJlciA9IDE7CiAgICBmb3IgKGludCBsaW5lID0gMTsgbGluZSA8PSBzaXplOyArK2xpbmUpIHsKICAgICAgICBudW1iZXIgKj0gLTE7CiAgICAgICAgZm9yIChpbnQgY29sID0gMTsgY29sIDw9IHNpemU7ICsrY29sKSB7CiAgICAgICAgICAgIC8qCiAgICAgICAgICAgIGlmIChsaW5lICUgMikgewogICAgICAgICAgICAgICAgLy9tdFtsaW5lXVtjb2xdID0gY29sICogb2RkTGluZXNOdW07CiAgICAgICAgICAgICAgICAvL2NvdXQgPDwgKG10W2xpbmVdW2NvbF0gPSBjb2wgKiBvZGRMaW5lc051bSkgPDwgIiAiOwogICAgICAgICAgICAgICAgY291dCA8PCBjb2wgKiBvZGRMaW5lc051bSA8PCAiICI7CiAgICAgICAgICAgIH0gZWxzZSB7CiAgICAgICAgICAgICAgICAvL210W2xpbmVdW2NvbF0gPSAoc2l6ZSAtIChjb2wgLSAxKSkgKiBldmVuTGluZXNOdW07CiAgICAgICAgICAgICAgICAvL2NvdXQgPDwgKG10W2xpbmVdW2NvbF0gPSAoc2l6ZSAtIChjb2wgLSAxKSkgKiBldmVuTGluZXNOdW0pIDw8ICIgIjsKICAgICAgICAgICAgICAgIGNvdXQgPDwgKHNpemUgLSAoY29sIC0gMSkpICogZXZlbkxpbmVzTnVtIDw8ICIgIjsKICAgICAgICAgICAgfQogICAgICAgICAgICAvL2NvdXQgPDwgbXRbbGluZV1bY29sXSA8PCIgIjsKICAgICAgICAgICAgKi8KICAgICAgICAgICAgb2RkQ3VycmVudEVsID0gbGluZSAlIDIgKiBjb2wgKiBvZGRMaW5lc051bTsKICAgICAgICAgICAgZXZlbkN1cnJlbnRFbCA9IChsaW5lICUgMiArIG51bWJlcikgKiAoc2l6ZSAtIChjb2wgLSAxKSkgKiBldmVuTGluZXNOdW07CiAgICAgICAgICAgIG10W2xpbmVdW2NvbF0gPSBvZGRDdXJyZW50RWwgKyBldmVuQ3VycmVudEVsOwogICAgICAgICAgICBjb3V0IDw8IG10W2xpbmVdW2NvbF0gPDwgIiAiOwogICAgICAgIH0KICAgICAgICBjb3V0IDw8ICJcbiI7CiAgICB9CiAgICByZXR1cm4gMDsKfQ==