#include <bits/stdc++.h>
using namespace std;
int main(int argc, char const *argv[]) {
  int n, m, l, r, x, p[10001], a[10001];
  scanf("%d %d", &n, &m);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", &p[i]);
  }
  while (m--) {
    scanf("%d %d %d", &l, &r, &x);
    if (x < l || x > r) {
      printf("Yes\n");
      continue;
    }
    int cnt1 = 0, cnt2 = 0;
    for (int i = l; i <= r; ++i) {
      if (i < x && p[i] > p[x]) cnt1++;
      if (i > x && p[i] < p[x]) cnt2++;
    }
    if (cnt1 == cnt2)
      printf("Yes\n");
    else
      printf("No\n");
  }
  return 0;
}
