#include <bits/stdc++.h>
using namespace std;
const int N = 1e4 + 5;
int a[N];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (int l, r, x, d; m--;) {
    scanf("%d%d%d", &l, &r, &x);
    d = 0;
    for (int i = l; i <= r; i++) d += a[i] < a[x];
    if (d + l == x)
      puts("Yes");
    else
      puts("No");
  }
  return 0;
}
