Hello, I got WA#6 But for few days I'm unable to find a test that fails for my algorithm. Does anyone has any hints? I would really appreciate any help. Di and Do may _COINCIDE_. Very good problem, thanks to authors! It took me almost a week to invent the easy solution. Don't ask how, just think. My test 4 1 4 0.0  1.1 0.1  1.2 0.2  1.3 0.2  0.3 0 3  7 why the answer is "7" but not "no solution" ? Try to draw labyrinth from my sample to inner level 3 and you see the path 03 exists. Read the problem statement once more. i can't understand it , there are only 1 inner house in your test , why should i draw labyrinth from your sample to inner level 3 ? and i always wa at Test #6 , i don't know why . Look at pictures 1 and 2 from problem statement. Every inner house is is copy of outer house and every inner house has its inner houses and etc... Can someone who got AC please send me the solution to email: dexter92.mg AT gmail.com I need exactly this problem to solve for my graduate work... (I promise I will not use the solution to get AC here, that is not my goal at all :) I actually found this problem here on Timus accidentally :)) Edited by author 20.04.2011 00:17 See my previous post... PLEASE PEOPLE can I get anyone's AC solution? I really need it for my graduate work... Again, this is my email: dexter92.mg@gmail.com ... Can you please send your code??? Thank you. Don't understand  the algorithm is just Floyd, and so few people solved this problem... Do you think I understand why I have WA#6? I had WA6 when I spread minimum over inner houses to all others (including outer). This is wrong, you should consider only outer house as a new inner one. But now I have WA16 :) Edited by author 27.08.2008 11:19 WA16 was that I added roads leading from some house to itself as such road for every house. This is also wrong. I start my solving with two hypotheses: 1. It is enough to use only one inner room. 2. Using this room it is enough edges between two rooms inner and outer consider as edges on boundary of outer room. It typical for contest. You achievements determined by your first quick considerations. WA6. Not so simple. More rightly to consider functional equation for dist[i,j].This equation solved by method of relaxation as a Laplas equation. AC at last. The problem indeed very simple and very based on the Floyd. But a man must have big contest experience to catch all logical moments. Edited by author 28.11.2008 20:58 
