#CCBCHBA0000032. Weighted Averages (Weighted Averages)
Weighted Averages (Weighted Averages)
Weighted Averages
Source: beecrowd
Version: Phuoc Hung OJ Extended
Problem Statement
The input contains t triples of numbers, each with one digit after the decimal point. Print each weighted mean with weights 2,3,5, one decimal per line.
Input
t in [1,1000]; then t triples of values in [0.0,10.0], each with exactly one decimal digit (PHOJ Extended bound).
Output
t lines, each weighted average (2a+3b+5*c)/10 with exactly one decimal place.
Subtasks
- Subtask 1 (20%): , điểm .
- Subtask 2 (30%): , điểm .
- Subtask 3 (50%): , điểm .
Examples
Example 1
Input
2
6.5 5.7 6.3
5.0 10.0 10.0
Output
6.2
9.0
Explanation
First weighted mean is 6.16, printed 6.2; second is 9.0.