#include <bits/stdc++.h>
using namespace std;
const double pi = acos(-1.0);
const double eps = 1e-7;
const long long MOD = 1000000009;
const int INF = 0x3f3f3f3f;
const int maxn = 1e4 + 10;
int n, m, arr[maxn];
int main(void) {
  scanf("%d%d", &n, &m);
  for (int i = 1; i <= n; ++i) scanf("%d", &arr[i]);
  for (int i = 0, l, r, x; i < m; ++i) {
    scanf("%d%d%d", &l, &r, &x);
    int cnt = 0;
    for (int j = l; j <= r; ++j)
      if (arr[j] < arr[x]) ++cnt;
    printf(cnt == x - l ? "Yes\n" : "No\n");
  }
  return 0;
}
