#include <bits/stdc++.h>
using namespace std;
bool b;
long long ans, cnt, arr[100000], sum;
string num_to_string(int num) {
  stringstream ss;
  ss << num;
  return ss.str();
}
void O_o() {
  ios::sync_with_stdio(0);
  ios_base::sync_with_stdio(0);
  cin.tie(0), cout.tie(0);
}
int main() {
  O_o();
  int n, m, x, y, z;
  cin >> n >> m;
  for (int i = 0; i < n; i++) cin >> arr[i];
  while (m--) {
    cnt = 0;
    cin >> x >> y >> z;
    x--;
    y--;
    z--;
    for (int i = x; i <= y; i++)
      if (arr[i] < arr[z]) cnt++;
    if (cnt == z - x)
      cout << "Yes" << endl;
    else
      cout << "No" << endl;
  }
  return 0;
}
