Search found 7 matches

by indyman
Sat Dec 02, 2006 6:15 am
Forum: Volume 100 (10000-10099)
Topic: 10054 - The Necklace
Replies: 62
Views: 31199

Another test case that could help debug WA is:
1
9
2 4
1 1
1 2
1 2
2 2
3 3
4 4
3 2
4 3

Hope it helps all!
by indyman
Fri Dec 01, 2006 10:37 am
Forum: Volume 101 (10100-10199)
Topic: 10199 - Tourist Guide
Replies: 57
Views: 30949

Jan,

Thank you very much for the test cases and advice. I figured out the error in my code. In my implementation of articulation points, I was calculating low using regular edges instead of the edges from the DFS tree. Doh! :))

Thanks a lot once again!
by indyman
Fri Dec 01, 2006 2:10 am
Forum: Volume 101 (10100-10199)
Topic: 10199 - Tourist Guide
Replies: 57
Views: 30949

Just as I thought. Thanks man. If you get any insights from my code, please let me know. I am thinking theres something wrong with the way I compute my low[] in the function low2[].

Thanks.
by indyman
Fri Dec 01, 2006 2:01 am
Forum: Volume 101 (10100-10199)
Topic: 10199 - Tourist Guide
Replies: 57
Views: 30949

Jan, I think the following test case also might help me figure out whats wrong: Input: 6 a b c d e f 4 a b a f c d d e 0 The output I get, is: City map #1: 1 camera(s) found a Although, if you make the graph, its like this: b ------ a ------- f c ------ d ------- e where there are two disjoint parts...
by indyman
Fri Dec 01, 2006 1:45 am
Forum: Volume 101 (10100-10199)
Topic: 10199 - Tourist Guide
Replies: 57
Views: 30949

Hi Jan, My code passed the above test cases you posted: This is the output: City map #1: 0 camera(s) found City map #2: 2 camera(s) found b d City map #3: 0 camera(s) found City map #4: 2 camera(s) found a z This is my code... Hope you can help.. Code Removed Hope you can help.... Thanks...
by indyman
Thu Nov 30, 2006 10:43 pm
Forum: Volume 101 (10100-10199)
Topic: 10199 - Tourist Guide
Replies: 57
Views: 30949

Jan,

Thanks for the output from your accepted code. I fxed my code and am getting the same answers for this input as you posted. Still WA. Any ideas as to which test cases might help? I am bummed.
by indyman
Thu Nov 30, 2006 12:42 pm
Forum: Volume 101 (10100-10199)
Topic: 10199 - Tourist Guide
Replies: 57
Views: 30949

Can anybody help me out? I am getting WA even though I get correct answers for all examples posted on this topic. What is the program really supposed to do for disconnected graphs? Many people have asked this before on this topic, but it hasnt really been answered yet. I am just wondering if thats w...

Go to advanced search