본문 바로가기
Beakjoon&프로그래머스/파이썬

[백준/파이썬] 30489번 apt upgrade

by 현장 2024. 1. 5.

-Code

n, m, k = map(int, input().split())
download = sorted(list(map(int, input().split())), reverse=True)
s = sum(download)
now = sum(download[:m + k])
res = now / s * 100

print(f"{res:.6f}")