#include <bits/stdc++.h>
using namespace std;
void go() {
  long long n;
  cin >> n;
  string a, w;
  cin >> a;
  for (long long i = 0; i < a.length(); i += 2) {
    w += a[i];
  }
  cout << w << '\n';
}
int main() {
  long long t;
  ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL);
  cin >> t;
  while (t--) go();
}
