#include <bits/stdc++.h>
using namespace std;
const int inf = (int)1e9;
const long long llinf = (long long)3e18;
const int N = (int)1e5 + 111;
const long double PI = (long double)acos(-1);
int main() {
  bool ok = false, is_swap = false;
  int n, x1, x2, mn, j, k1, k2;
  scanf("%d %d %d", &n, &x1, &x2);
  vector<pair<int, int> > arr1(n), arr2;
  vector<int> a(n), b, ans1, ans2;
  for (int i = 0; i < n; i++) {
    scanf("%d", &arr1[i].first);
    arr1[i].second = i + 1;
  }
  sort(arr1.begin(), arr1.end());
  for (int i = 0; i < n; i++) a[i] = arr1[i].first;
  for (int i = 0; i < n; i++) printf("%d ", a[i]);
  printf("\n");
  for (k2 = 1; k2 <= n; k2++) {
    mn = (x2 + k2 - 1) / k2;
    j = (int)(lower_bound(a.begin(), a.end(), mn) - a.begin());
    k1 = n - j - k2;
    if (n - j > k2 && (a[j + k2] >= (x1 + k1 - 1) / k1)) {
      ok = true;
      for (int i = j; i < j + k2; i++) ans2.push_back(arr1[i].second);
      for (int i = j + k2; i < n; i++) ans1.push_back(arr1[i].second);
      break;
    }
    mn = (x1 + k2 - 1) / k2;
    j = (int)(lower_bound(a.begin(), a.end(), mn) - a.begin());
    k1 = n - j - k2;
    if (n - j > k2 && (a[j + k2] >= (x2 + k1 - 1) / k1)) {
      ok = true;
      for (int i = j; i < j + k2; i++) ans1.push_back(arr1[i].second);
      for (int i = j + k2; i < n; i++) ans2.push_back(arr1[i].second);
      break;
    }
  }
  if (ok) {
    if (!is_swap) {
      printf("Yes\n%d %d", k1, k2);
      printf("\n");
      for (int i = 0; i < k1; i++) printf("%d ", ans1[i]);
      printf("\n");
      for (int i = 0; i < k2; i++) printf("%d ", ans2[i]);
    } else {
      printf("Yes\n%d %d", k2, k1);
      printf("\n");
      for (int i = 0; i < k2; i++) printf("%d ", ans2[i]);
      printf("\n");
      for (int i = 0; i < k1; i++) printf("%d ", ans1[i]);
    }
  } else
    printf("No");
  return 0;
}
