Please note: the language of this site will now be ENGLISH. Please do not use another language since visitors from different countries will participate in training.

Week 13 - Misc

The tasks for week 13 are as follows:

Week problem: 10816 Travel in Desert
Weekend problem: 11262 Weird Fence
Suggested bonus: 10891 Game of Sum

You must submit your solutions on

You can browse to these problems from the online judge website by clicking on Browse Problems, Contest Volumes, and then selecting the contest volume as indicated above.

asked Aug 29, 2012 in Tasks by eljakimit

Please post below which of the questions you have been able to finish.

For each task, please let us know how much time you have spent on understanding / coding / debugging.

For each task let us know what the hardest part was. (This can be anything, ranging from not having read the problem to forgetting about a border case, to a semicolon in the wrong spot that screwed up an if-statement...)

1 Answer

0 votes

YEAH my travel in desert solution was accepted at once.
I can say now that I have Dijkstra with a priority queue perfectly under the knee

answered Sep 6, 2012 by bvdbijl

I'm actually beginning to hate that question, it's looked very simple but I got WA. And I was too lazy too think of border cases so I looked on the internet (something I really should stop doing, but ok..). Then I fixed my algorithm, and it passed all test cases is searched for and I wrote myself but still keeping WA. Think I could better begin again from the begin :(.

Hmm, interesting, I thought it was pretty straight forward. My solution is a combination of a BFS and Dijkstra's

Yeah, i first tried to do it in one Dijkstra, taking the lowest temperature path and if they are equal then taking the shortest path, but that failed on this sort of inputs:
3 3
1 3
1 2 10.0 10.0
1 2 11.0 9.0
2 3 11.0 10.0
Then I did two dijkstra (although dijkstra and bfs is also good) and that seems to work, but it wasn't accepted :(.