#include <bits/stdc++.h>
using namespace std;
const int nax = 4005;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int t;
  cin >> t;
  while (t--) {
    int n;
    cin >> n;
    vector<int> a(2 * n);
    for (int i = 0; i < 2 * n; i++) {
      cin >> a[i];
    }
    bitset<nax> dp;
    dp[0] = 1;
    int len = 1;
    int last = 0;
    for (int i = 1; i < 2 * n; i++) {
      if (a[i] > a[last]) {
        dp |= dp << len;
        len = 1;
        last = i;
      } else
        len++;
    }
    dp |= dp << len;
    cout << (dp[n] ? "YES\n" : "NO\n");
  }
  return 0;
}
