#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1);
const double eps = 1e-9;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  long long i, j, k, l, p, q, x, y, z, n, m, c, t, h, r;
  cin >> n >> m;
  long long arr[n + 1];
  for (i = 1; i < n + 1; i++) cin >> arr[i];
  for (j = 0; j < m; j++) {
    cin >> l >> r >> x;
    if (r - l + 1 == n) {
      if (arr[x] == x)
        cout << "Yes\n";
      else
        cout << "No\n";
      continue;
    }
    k = l;
    for (i = l; i <= r; i++) {
      if (arr[i] < arr[x]) k++;
    }
    if (arr[x] == arr[k])
      cout << "Yes\n";
    else
      cout << "No\n";
  }
}
