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