编程介的小学生 2017-07-16 02:31 采纳率: 20.5%
浏览 752
已采纳

Osu!

Problem Description
Osu! is a famous music game that attracts a lot of people. In osu!, there is a performance scoring system, which evaluates your performance. Each song you have played will have a score. And the system will sort all you scores in descending order. After that, the i-th song scored ai will add 0.95^(i-1)*ai to your total score.

Now you are given the task to write a calculator for this system.

Input
The first line contains an integer T, denoting the number of the test cases.

For each test case, the first line contains an integer n, denoting the number of songs you have played. The second line contains n integers a1, a2, ..., an separated by a single space, denoting the score of each song.

T<=20, n<=50, 1<=ai<=500.

Output
For each test case, output one line for the answer.

Your answers will be considered correct if its absolute error is smaller than 1e-5.

Sample Input
1
2
530 478

Sample Output
984.1000000000

  • 写回答

1条回答 默认 最新

  • devmiao 2017-07-30 13:45
    关注
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 MATLAB怎么通过柱坐标变换画开口是圆形的旋转抛物面?
  • ¥15 寻一个支付宝扫码远程授权登录的软件助手app
  • ¥15 解riccati方程组
  • ¥15 display:none;样式在嵌套结构中的已设置了display样式的元素上不起作用?
  • ¥30 用arduino开发esp32控制ps2手柄一直报错
  • ¥15 使用rabbitMQ 消息队列作为url源进行多线程爬取时,总有几个url没有处理的问题。
  • ¥15 Ubuntu在安装序列比对软件STAR时出现报错如何解决
  • ¥50 树莓派安卓APK系统签名
  • ¥65 汇编语言除法溢出问题
  • ¥15 Visual Studio问题