#include <iostream>
using namespace std;
const int MAX_SIZE = 10;
int main() {
int n, currentElement, aux[MAX_SIZE + 1][MAX_SIZE + 1];
cin >> n;
for (int i = 1; i <= n; ++i) {
for (int j = 1; j <= n; ++j) {
cin >> currentElement;
aux[j][i] = currentElement;
}
}
for (int i = 1; i <= n; ++i) {
for (int j = 1; j <= n; ++j) {
cout << aux[i][j] << " ";
}
cout << "\n";
}
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwogCmNvbnN0IGludCBNQVhfU0laRSA9IDEwOwogCmludCBtYWluKCkgewoJaW50IG4sIGN1cnJlbnRFbGVtZW50LCBhdXhbTUFYX1NJWkUgKyAxXVtNQVhfU0laRSArIDFdOwoJY2luID4+IG47Cglmb3IgKGludCBpID0gMTsgaSA8PSBuOyArK2kpIHsKCQlmb3IgKGludCBqID0gMTsgaiA8PSBuOyArK2opIHsKCQkJY2luID4+IGN1cnJlbnRFbGVtZW50OwoJCQlhdXhbal1baV0gPSBjdXJyZW50RWxlbWVudDsKCQl9Cgl9Cglmb3IgKGludCBpID0gMTsgaSA8PSBuOyArK2kpIHsKCQlmb3IgKGludCBqID0gMTsgaiA8PSBuOyArK2opIHsKCQkJY291dCA8PCBhdXhbaV1bal0gPDwgIiAiOwoJCX0KCQljb3V0IDw8ICJcbiI7Cgl9CglyZXR1cm4gMDsKfQ==