#include<stdio.h>
int main(void){
  char *s="python3 -c\""
"n,a,b,*v=map(int,open(0).read().split())\n"
"v=[0]+v\n"
"dp=[[[0,1]]+[[0,0]for j in range(b)]for i in range(n+1)]\n"
"for i in range(1,n+1):\n"
"  for j in range(1,b+1):\n"
"    if dp[i-1][j-1][0]+v[i]>dp[i-1][j][0]:\n"
"      dp[i][j]=[dp[i-1][j-1][0]+v[i],dp[i-1][j-1][1]]\n"
"    elif dp[i-1][j-1][0]+v[i]==dp[i-1][j][0]:\n"
"      dp[i][j]=[dp[i-1][j][0],dp[i-1][j][1]+dp[i-1][j-1][1]]\n"
"    else:\n"
"      dp[i][j]=[dp[i-1][j][0],dp[i-1][j][1]]\n"
"m=0\n"
"for i in range(a,b+1):\n"
"  m=max(m,dp[-1][i][0]/i)\n"
"print(m,sum(dp[-1][i][1]*(dp[-1][i][0]/i==m)for i in range(a,b+1)),sep='\n')\n"
"\"";
  system(s);
  return 0;
}            