Guest User

Untitled

a guest
Dec 11th, 2017
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. Input - A 3 B 4 A 1 A 1
  2. Output - 3.56
  3. Explanation: (4.0 * 3 + 3.0 * 4 + 4.0 * 1 + 4.0 * 1)/(3+4+1+1) = 3.555556 rounded off to 3.57
  4.  
  5. Input - A 4 F 2 C 3 D 4
  6. Output - 2.23
  7. Explanation: (4.0 * 4 + 0.0 * 2 + 2.0 * 3 + 1.0 * 4)/(4+2+3+4) = 3 rounded off to 3.00
Add Comment
Please, Sign In to add comment