#include <bits/stdc++.h>
int arr[10004];
int main() {
  int n, m;
  scanf("%d %d", &n, &m);
  for (int _k = (1), _n = (n), i = _k; i <= _n; ++i) scanf("%d", &arr[i]);
  for (int _k = (1), _n = (m), i = _k; i <= _n; ++i) {
    int l, r, x;
    scanf("%d %d %d", &l, &r, &x);
    int t = 0, a = arr[x];
    for (int _k = (l), _n = (r), j = _k; j <= _n; ++j)
      if (arr[j] < a) ++t;
    if (l + t == x)
      printf("Yes\n");
    else
      printf("No\n");
  }
  return 0;
}
