#include <bits/stdc++.h>
using namespace std;

#define CPP_STR(x) CPP_STR_I(x)
#define CPP_CAT(x,y) CPP_CAT_I(x,y)
#define CPP_STR_I(args...) #args
#define CPP_CAT_I(x,y) x ## y

using i8  = int8_t;
using u8  = uint8_t;
using i16 = int16_t;
using u16 = uint16_t;
using i32 = int32_t;
using u32 = uint32_t;
using i64 = int64_t;
using u64 = uint64_t;

using f32 = float;
using f64 = double;

#define FOR(i, start, end) for(i64 i = (start), CPP_CAT(i,xxxx_end)=(end); i < CPP_CAT(i,xxxx_end); ++i)
#define REP(i, n) FOR(i, 0, n)
#define REPS(i, n) for(i64 i = 1; i <= n; ++i)
#define RREP(i, n) for(i64 i = n - 1; i >= 0 ; --i)
#define RREPS(i, n) for(i64 i = n; i >= 1; --i)

#define ALL(f,c,...) (([&](decltype((c)) cccc) { return (f)(std::begin(cccc), std::end(cccc), ## __VA_ARGS__); })(c))

#define UNIQUE(v) v.erase( unique(v.begin(), v.end()), v.end() );

#define pb push_back
#define mp make_pair

template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }

template<typename C>
i64 SIZE(const C& c) { return static_cast<i64>(c.size()); }

template<typename T, size_t N>
i64 SIZE(const T (&)[N]) { return static_cast<i64>(N); }


struct ProconInit {
    static constexpr int IOS_PREC = 15;
    static constexpr bool AUTOFLUSH = false;

    ProconInit() {
        cin.tie(nullptr);
        ios::sync_with_stdio(false);
        cout << fixed << setprecision(IOS_PREC);
        if(AUTOFLUSH)
            cout << unitbuf;
    }
} PROCON_INIT;


int main() {
    i64 N, A, B; cin >> N >> A >> B;
    vector<i64> V(N);
    REP(i, N) cin >> V[i];

    using P = pair<i64, i64>;
    auto solve = [&](i64 nc) {
        vector<vector<P>> dp(N + 1, vector<P>(N + 1, {0, 0}));
        dp[0][0] = {0, 1};
        REP(i, N) {
            for (i64 j = 0; j <= i; j++) {
                if (dp[i + 1][j].first == dp[i][j].first) {
                    dp[i + 1][j].second += dp[i][j].second;
                } else if (dp[i + 1][j].first < dp[i][j].first) {
                    dp[i + 1][j].first = dp[i][j].first;
                    dp[i + 1][j].second = dp[i][j].second;
                }

                i64 nv = dp[i][j].first + V[i];
                if (dp[i + 1][j + 1].first == nv) {
                    dp[i + 1][j + 1].second += dp[i][j].second;
                } else if (dp[i + 1][j + 1].first < nv) {
                    dp[i + 1][j + 1].first = nv;
                    dp[i + 1][j + 1].second = dp[i][j].second;
                }
            }
        }
        return dp[N][nc];
    };

    P maxmean = {0, 1};
    i64 npattern = 0;
    auto comp = [&](P p1, P p2) {
        i64 g1 = gcd(p1.first, p1.second);
        i64 g2 = gcd(p2.first, p2.second);
        p1.first /= g1, p1.second /= g1;
        p2.first /= g2, p2.second /= g2;

        i64 x = p1.first * p2.second;
        i64 y = p2.first * p1.second;
        if (x == y) return 0;
        else if (x < y) return 1;
        else return -1;
    };
    for (i64 nc = A; nc <= B; nc++) {
        auto [s, p] = solve(nc);
        P nm = {s, nc};
        if (comp(maxmean, nm) == 0) npattern += p;
        else if (comp(maxmean, nm) == 1) maxmean = nm, npattern = p;
    }
    cout << (maxmean.first / (long double)(maxmean.second)) << endl;
    cout << npattern << endl;

    return 0;
}


Measured memory_bytes: 3804