import core.bitop;
import std.algorithm;
import std.ascii;
import std.bigint;
import std.conv;
import std.functional;
import std.math;
import std.numeric;
import std.range;
import std.stdio;
import std.string;
import std.random;
import std.typecons;
import std.container;

struct List
{
    List* next;
    List* prev;
    long deta;

    this(long deta)
    {
        this.deta = deta;
    }
}

void initList(List* head)
{
    head.next = head.prev = head;
}

void addbefore(List* head, List* add)
{
    add.next = head;
    add.prev = head.prev;
    head.prev.next = add;
    head.prev = add;
}

void addafter(List* tail, List* add)
{
    add.next = tail.next;
    add.prev = tail;
    tail.next.prev = add;
    tail.next = add;
}

void printfirst(List* head, List* tail)
{
    while (head != tail)
    {
        head.deta.write(" ");
        head = head.next;
    }
    head.deta.writeln();
}

void printlast(List* tail, List* head)
{
    while (tail != head)
    {
        tail.deta.write(" ");
        tail = tail.prev;
    }
    tail.deta.writeln();
}

void main()
{
    auto n = readln.chomp.to!(long);
    auto a = readln.split.to!(long[]);
    auto head = new List;
    auto tail = new List;
    bool flag;
    foreach (i, e; a)
    {
        if(i == 0)
        {
            auto elem = new List(e);
            initList(elem);
            head = tail = elem;
            continue;
        }
        if(flag)
        {
            auto add = new List(e);
            addbefore(head, add);
            head = head.prev;
        }
        else
        {
            auto add = new List(e);
            addafter(tail, add);
            tail = tail.next;
        }
        flag = !flag;
    }
    if(flag)
        printlast(tail, head);
    else
        printfirst(head, tail);
}
