#include <bits/stdc++.h>
using namespace std;
int n, m;
int l, r, x;
int p[10005];
int main() {
  cin >> n >> m;
  for (int i = 1; i <= n; i++) cin >> p[i];
  for (int i = 1; i <= m; i++) {
    cin >> l >> r >> x;
    int k = 0;
    for (int i = l; i <= r; i++)
      if (p[i] < p[x]) k++;
    if (p[l + k] == p[x])
      cout << "Yes" << endl;
    else
      cout << "No" << endl;
  }
  return 0;
}
