#include <bits/stdc++.h>
using namespace std;
int N, N1, N2;
long long A[100100];
int main() {
  cin >> N >> N1 >> N2;
  for (int i = 0; i < N; i++) cin >> A[i];
  sort(A, A + N);
  long long S = 0, sumN1 = 0, sumN2 = 0;
  for (int i = N - 1; i >= N - N1 - N2; i--) {
    S += A[i];
    if (i >= N - N1) sumN1 += A[i];
    if (i >= N - N2) sumN2 += A[i];
  }
  long long ans =
      max(N2 * sumN1 + N1 * (S - sumN1), N2 * (S - sumN2) + N1 * sumN2);
  printf("%.10f\n", 1.0 * ans / N1 / N2);
  return 0;
}
