#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  cin >> t;
  while (t--) {
    long long int p1, p2;
    long long int n;
    cin >> n;
    long long int a[n];
    for (int i = 0; i < n; i++) {
      cin >> a[i];
    }
    if (n == 1) {
      cout << "Yes" << endl;
    } else {
      int count = 0, dount = 0;
      for (int i = 0; i < n; i++) {
        if (a[i] >= i) {
        } else {
          p1 = i;
          count = 1;
          break;
        }
      }
      long long int m = 0;
      for (int i = n - 1; i >= 0; i--) {
        if (a[i] >= m) {
        } else {
          p2 = i;
          dount = 1;
          break;
        }
        m++;
        ;
      }
      if (count == 0 || dount == 0)
        cout << "Yes" << endl;
      else {
        int count = 0, dount = 0;
        if (p1 >= 1) p1--;
        long long int m = 0;
        for (int i = n - 1; i >= p1; i--) {
          if (a[i] >= m) {
          } else {
            dount = 1;
            break;
          }
          m++;
          ;
        }
        if (p2 >= 1) p2--;
        for (int i = p2; i < n; i++) {
          if (a[i] >= i) {
          } else {
            count = 1;
            break;
          }
        }
        if (count == 0 || dount == 0)
          cout << "Yes" << endl;
        else
          cout << "No" << endl;
      }
    }
  }
  return 0;
}
