#include <bits/stdc++.h>
using namespace std;
int read() {
  int ng = 0, x = 0;
  char ch = getchar();
  for (; ch < '0' || ch > '9'; ch = getchar()) ng |= ch == '-';
  for (; ch >= '0' && ch <= '9'; ch = getchar())
    x = (x << 3) + (x << 1) + ch - '0';
  return ng ? -x : x;
}
long long gcd(long long x, long long y) { return !x ? y : gcd(y % x, x); }
void exgcd(long long a, long long b, long long &x, long long &y) {
  if (!b) {
    x = 1;
    y = 0;
    return;
  }
  exgcd(b, a % b, y, x);
  y -= a / b * x;
}
long long qp(long long a, long long p) {
  if (p < 0) return 0;
  long long ans = 1;
  while (p) {
    if (p & 1) ans = ans * a;
    a = a * a;
    p >>= 1;
  }
  return ans;
}
long long qp(long long a, long long p, long long M) {
  long long ans = 1;
  while (p) {
    if (p & 1) ans = ans * a % M;
    a = a * a % M;
    p >>= 1;
  }
  return ans;
}
const int maxn = 1e5 + 10;
int n;
int a[maxn];
vector<int> vec;
int pos[maxn], vis[maxn];
unordered_set<int> s;
vector<int> add;
int main() {
  int __;
  scanf("%d", &__);
  while (__--) {
    s.clear();
    memset((vis), 0, sizeof(vis));
    vec.clear();
    scanf("%d", &n);
    for (int i = 0; i < 2 * n; i++) {
      scanf("%d", a + i);
      pos[a[i]] = i;
    }
    int top = 2 * n;
    for (int i = 2 * n; i >= 1; i--)
      if (!vis[i]) {
        for (int j = pos[i]; j < top; j++) vis[a[j]] = 1;
        vec.push_back(top - pos[i]);
        top = pos[i];
      }
    sort(vec.begin(), vec.end());
    top = (int)vec.size();
    s.insert(vec[0]);
    for (int i = 1; i < top; i++) {
      add.clear();
      for (auto x : s)
        if (x <= n) add.push_back(x + vec[i]);
      for (auto x : add)
        if (x <= n) s.insert(x);
    }
    puts(s.count(n) == 1 ? "YES" : "NO");
  }
  return 0;
}
