#include <iostream>
using namespace std;
int main()
{
int n, v[100];
cin >> n;
for(int i = 0; i < n; i++)
{
cin >> v[i];
}
int i = 0, j = n - 1;
while(i < j)
{
cout << v[j] << " " << v[i] << endl;
i++;
j--;
}
if(i == j)
{
cout << v[i] << endl;
}
return 0;
}