#include <bits/stdc++.h>

using namespace std;

int main(){
    int t;
    cin >> t;
    while (t--){
        int n;
        cin >> n;
        vector <int> a(n);
        for (int i=0;i<n;i++){
            cin >> a[i];
        }
        int l=0,r=n-1,k;
        for (int i=l;r-l>=0;){
            cout << a[i] << " ";
            if (i==l){
                l++;
                i=r;
            }
            else{
                r--;
                i=l;
            }
        }
        cout << "\n";
    }
    return 0;
}
