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

Common Board

Chase in SUbWay 1313 - help me please
Posted by Thadeu Russo - UAM 28 Apr 2004 04:26
how to determinate the shortest way for criminal???
why the criminal goes to 85 and no to 10????

we have..

   61--62
   |
   50
   |
   85
   |
10-20-30
   |
   75

He starts at 30, goes to 20 and goes to 85.. why?????
i used bfs to search the ways than are possibles shelters but i have WA in test 4.

Re: Chase in SUbWay 1313 - help me please
Posted by ronobe (aka oberon) 28 Apr 2004 12:26
The criminal moves by the shortest route from one vertex to another. But you do not know his destination point. You are to determine this destination point, knowing that shortest path to some station contains (sequentially) stations 30, 20 and 85. One of the best routes to vertex 61 contains this stations (sequentially), so his goal point may be point 61.
Re: Chase in SUbWay 1313 - help me please
Posted by Thadeu Russo - UAM 29 Apr 2004 01:41
i think this yesterday on the bus hehehehehe


thanx....