#include <iostream>
using namespace std;
int main() {
int n;
cin >> n;
int liczby[100000];
for (int i = 0; i < n; ++i) {
cin >> liczby[i];
}
for (int i = n / 2; i < n; ++i) {
cout << liczby[i] << " ";
}
for (int i = 0; i < n / 2; ++i) {
cout << liczby[i] << " ";
}
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgoKdXNpbmcgbmFtZXNwYWNlIHN0ZDsKCmludCBtYWluKCkgewogICAgaW50IG47CiAgICBjaW4gPj4gbjsKCiAgICBpbnQgbGljemJ5WzEwMDAwMF07CgogICAgZm9yIChpbnQgaSA9IDA7IGkgPCBuOyArK2kpIHsKICAgICAgICBjaW4gPj4gbGljemJ5W2ldOwogICAgfQoKICAgIGZvciAoaW50IGkgPSBuIC8gMjsgaSA8IG47ICsraSkgewogICAgICAgIGNvdXQgPDwgbGljemJ5W2ldIDw8ICIgIjsKICAgIH0KCiAgICBmb3IgKGludCBpID0gMDsgaSA8IG4gLyAyOyArK2kpIHsKICAgICAgICBjb3V0IDw8IGxpY3pieVtpXSA8PCAiICI7CiAgICB9CgogICAgcmV0dXJuIDA7Cn0=