import java.util.*

fun main(args: Array<String>) {
	val (n, a, b) = readLine()!!.split(" ").map { it.toInt() }
	val values = readLine()!!.split(" ").map { it.toLong() }.toLongArray()
	values.sort()
	values.reverse()
	val sum = (0..(a - 1)).fold(0L) { acc, i -> acc + values[i] }
	val ans = sum.toDouble() / a.toDouble()
	println("%.6f".format(ans))
	val v = values[a - 1]
	var r = (0..(a - 1)).fold(0) { acc, i -> if (values[i] == v) { acc + 1 } else { acc } }
	val num = (0..(n - 1)).fold(0) { acc, i -> if (values[i] == v) { acc + 1 } else { acc } }
	var prv = 1L
	for (i in 1..r) {
		prv = (prv * (num - i + 1)) / i
	}
	var total = prv
	if (r != a) {
		println(total)
		return
	}
	for (i in (r + 1)..(r + b - a)) {
		val pattern = (prv * (num - i + 1)) / i
		prv = pattern
		total += pattern
	}
	println(total)
}
