#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
const double pi = acos(-1.0);
void cp();
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long lcm(long long a, long long b) { return (a / gcd(a, b)) * b; }
long long fact(long long n) {
  if (n <= 1) return n;
  return n * fact(n - 1);
}
bool prime[100001];
void sieve() {
  int n = 10000;
  memset(prime, true, sizeof(prime));
  for (int p = 2; p * p <= n; p++) {
    if (prime[p] == true) {
      for (int i = p * p; i <= n; i += p) prime[i] = false;
    }
  }
}
void solve() {
  int n, i;
  cin >> n;
  string s;
  cin >> s;
  for (i = 0; i <= (2 * n) - 1; i++) {
    if (i % 2 == 0) cout << s[i];
  }
  cout << "\n";
}
int main() {
  cp();
  int t;
  cin >> t;
  while (t--) solve();
  return 0;
}
void cp() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
}
