void main()
{
    long n, a, b;
    rdVals(n, a, b);
    long[] v = rdRow;

    long[][] comb = new long[][](n+1, n+1);
    comb[0][0] = 1;
    foreach (i; 1 .. n+1)
    {
        comb[i][0] = 1;
        foreach (j; 1 .. i+1)
        {
            comb[i][j] = comb[i-1][j-1] + comb[i-1][j];
        }
    }

    v.sort!"a > b";
    auto g = v.group.array;
    long num;
    long total;
    foreach (x; g)
    {
        if (num + x[1] < a)
        {
            num += x[1], total += x[0];
            continue;
        }

        double ave;
        long cnt;
        if (total)
        {
            long diff = a - num;
            total += x[0] * diff;
            ave = total.to!double / a;
            cnt = comb[x[1]][diff];
        }
        else
        {
            long m = min(x[1], b);
            ave = x[0].to!double;
            foreach (i; a .. m+1)
            {
                cnt += comb[x[1]][i];
            }
        }

        writefln("%.9f", ave);
        cnt.writeln;
        return;
    }
}

enum long mod = 10L^^9 + 7;
enum long inf = 1L << 60;
enum double eps = 1.0e-9;

T rdElem(T = long)()
if (!is(T == struct))
{
    return readln.chomp.to!T;
}

alias rdStr = rdElem!string;
alias rdDchar = rdElem!(dchar[]);

T rdElem(T)()
if (is(T == struct))
{
    T result;
    string[] input = rdRow!string;
    assert(T.tupleof.length == input.length);
    foreach (i, ref x; result.tupleof)
    {
        x = input[i].to!(typeof(x));
    }
    return result;
}

T[] rdRow(T = long)()
{
    return readln.split.to!(T[]);
}

T[] rdCol(T = long)(long col)
{
    return iota(col).map!(x => rdElem!T).array;
}

T[][] rdMat(T = long)(long col)
{
    return iota(col).map!(x => rdRow!T).array;
}

void rdVals(T...)(ref T data)
{
    string[] input = rdRow!string;
    assert(data.length == input.length);
    foreach (i, ref x; data)
    {
        x = input[i].to!(typeof(x));
    }
}

void wrMat(T = long)(T[][] mat)
{
    foreach (row; mat)
    {
        foreach (j, compo; row)
        {
            compo.write;
            if (j == row.length - 1) writeln;
            else " ".write;
        }
    }
}

import std.stdio;
import std.string;
import std.array;
import std.conv;
import std.algorithm;
import std.range;
import std.math;
import std.numeric;
import std.mathspecial;
import std.traits;
import std.container;
import std.functional;
import std.typecons;
import std.ascii;
import std.uni;
import core.bitop;