from sys import stdin, stdout
from bisect import *

rint = lambda: int(stdin.readline())
rints = lambda: [int(x) for x in stdin.readline().split()]
rint_2d = lambda n: [rint() for _ in range(n)]
rints_2d = lambda n: [rints() for _ in range(n)]
rint_enu = lambda: [(int(x), i + 1) for i, x in enumerate(rints())]
pr = lambda args, sep: stdout.write(sep.join(map(str, args)) + '\n')
ceil1, out = lambda a, b: (a + b - 1) // b, []
get_col = lambda arr, i: [row[i] for row in arr]


def min_arr(a):
    tem = [float('inf')]
    for i in range(len(a)):
        tem.append(min(tem[-1], a[i]))
    return tem


n, s1, s2 = rints()
a, ans = rints(), 'No'
mi, mem, ma = min(s1, s2), [n + 1] * (n - 1), max(s1, s2)
ixs = sorted(range(n), key=lambda x: a[x])
col = [a[x] for x in ixs]

for i in range(1, min(mi + 1, n)):
    div = ceil1(mi, i)
    ix = bisect_left(col, div)
    if ix != n:
        mem[i - 1] = ix + i

cum = min_arr(mem)

for i in range(1, min(ma + 1, n)):
    div = ceil1(ma, i)

    if div <= col[n - i] and cum[n - i] <= n - i:
        t1, t2 = [], []
        for j in range(n - i, n):
            t1.append(ixs[j] + 1)

        for j in range(n - i - 1, -1, -1):
            if mem[j] <= n - i:
                for k in range(mem[j] - 1, mem[j] - (j + 1) - 1, -1):
                    t2.append(ixs[k] + 1)
                break

        if s1 < s2:
            t1, t2 = t2, t1
        print('Yes\n%d %d\n%s\n%s' % (len(t1), len(t2), ' '.join(map(str, t1)), ' '.join(map(str, t2))))
        exit()

mem = [n + 1] * (n - 1)
for i in range(1, min(ma + 1, n)):
    div = ceil1(ma, i)
    ix = bisect_left(col, div)
    if ix != n:
        mem[i - 1] = ix + i

cum = min_arr(mem)

for i in range(1, min(mi + 1, n)):
    div = ceil1(mi, i)

    if div <= col[n - i] and cum[n - i] <= n - i:
        t1, t2 = [], []
        for j in range(n - i, n):
            t1.append(ixs[j] + 1)

        for j in range(n - i - 1, -1, -1):
            if mem[j] <= n - i:
                for k in range(mem[j] - 1, mem[j] - (j + 1) - 1, -1):
                    t2.append(ixs[k] + 1)
                break

        if s1 > s2:
            t1, t2 = t2, t1
        print('Yes\n%d %d\n%s\n%s' % (len(t1), len(t2), ' '.join(map(str, t1)), ' '.join(map(str, t2))))
        exit()
print('No')
