ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1119. Metro

how is output 383 and not 241 for sample cases
Posted by Mayank Punetha 24 Feb 2014 14:45
first the person goes to (2,2) from (1,1) +141 then (3,2) +100 so why not 241?
Re: how is output 383 and not 241 for sample cases
Posted by Dron-elektron 26 Jul 2014 17:16
(0, 0) -> (1, 1) = sqrt(2) * 100
(1, 1) -> (2, 1) = 100
(2, 1) -> (3, 2) = sqrt(2) * 100

Total: 382.842712475 ~ 383

Edited by author 26.07.2014 17:17
Re: how is output 383 and not 241 for sample cases
Posted by Anant Kaushik 26 Sep 2014 00:05
Then shouldnt the problem wording be stated as rounding the solution to the nearest integer? If I just round 382.84 to its integer value, it would be 382.