#include <bits/stdc++.h>
using namespace std;
long long GCD(long long a, long long b) { return b ? GCD(b, a % b) : a; }
long long lcm(long long a, long long b) { return a * b / GCD(a, b); }
int lb(int x) { return x & (-x); }
const long long N = 2e3 + 7;
const long long inf = 1e9 + 1;
const long long mod = 1e9 + 7;
const int P = 131;
const double eps = 1e-6;
const double dbinf = 1e18 + 7;
int t, n, x;
int a[N << 1];
bool vis[N << 1];
int pos[N << 1];
int dp[N << 1];
int find(int x) {
  for (int i = x - 1; i >= 1; i--) {
    if (vis[i] == false) return i;
  }
  return 0;
}
int main() {
  cin >> t;
  while (t--) {
    cin >> n;
    for (int i = 1; i <= n << 1; i++)
      cin >> x, pos[x] = i, vis[i] = false, a[i] = x, dp[i] = 0;
    int maxn = n << 1 | 1;
    int lena = 0, lenb = 0;
    int r = n << 1;
    bool ok = true;
    vector<int> tmp(1);
    while (r >= 1) {
      maxn = find(maxn);
      int l = pos[maxn];
      int len = r - l + 1;
      tmp.push_back(len);
      for (int i = l; i <= r; i++) vis[a[i]] = true;
      r = l - 1;
    }
    int sz = tmp.size();
    for (int i = 1; i <= sz - 1; i++) {
      for (int j = n; j >= tmp[i]; j--) {
        dp[j] = max(dp[j], dp[j - tmp[i]] + tmp[i]);
      }
    }
    cout << (dp[n] == n ? "YES\n" : "NO\n");
  }
  return 0;
}
