Search found 570 matches

by Observer
Mon Jan 14, 2008 9:20 am
Forum: Volume 113 (11300-11399)
Topic: 11391 - Blobs in the Board
Replies: 10
Views: 4476

Make sure that your code do not do the calculations more than once.
by Observer
Sun Jan 13, 2008 6:35 pm
Forum: Volume 113 (11300-11399)
Topic: 11386 - Triples
Replies: 23
Views: 8556

If you have grouped the numbers, then the O(n^2) is very obvious. :)

Hint: suppose we are to find tuples (X, y, z), where X is fixed. Think of how to do so in O(n).

There are many other ways to get O(n^2) solutions for this task.
by Observer
Sat Jan 12, 2008 8:35 pm
Forum: Volume 113 (11300-11399)
Topic: 11394 - Digit Blocks
Replies: 18
Views: 9002

I love this kind of problems! :D

I should have participated in the contest.. Forgotten the contest time...... I would have solved 9 problems (haven't read F yet). :(
by Observer
Sat Jan 12, 2008 8:02 pm
Forum: Volume 113 (11300-11399)
Topic: 11386 - Triples
Replies: 23
Views: 8556

Sorry. I was only talking about my own algorithm. :D I use for loop only for smallest and largest number in the tuple. It is also good to "group" the repeated numbers.
by Observer
Sat Jan 12, 2008 6:06 pm
Forum: Volume 113 (11300-11399)
Topic: 11386 - Triples
Replies: 23
Views: 8556

So does the obvious O(n^2) solution work? And how big can the input integers be? Just less than 2^31?

[EDIT] Accepted. Let me answer my questions: O(n^2) works. Have to use 64-bit ints in the code.
by Observer
Fri Jan 11, 2008 7:12 am
Forum: Bugs and suggestions
Topic: More test cases, please - 0.000 secs is boring
Replies: 3
Views: 2159

I don't think it is a very good idea. Well in a programming contest we need some easy problems, some of which solvable in constant time (i.e. O(1)). If we are to increase the test data, then the problem doesn't really get any harder, but most of the runtime would be spent on I/O, which might not be ...
by Observer
Tue Jan 08, 2008 10:05 pm
Forum: Volume 113 (11300-11399)
Topic: 11383 - Golden Tiger Claw
Replies: 10
Views: 2514

I'm greatly pulling down the acceptance rate... :- )

Could anyone offer some test cases? I am getting WA...

[EDIT] Never mind. I've found a stupid flaw in my alternate-path finding routine. Now I'm facing TLE.

[EDIT] Accepted. Now with the slowest time in ranklist~
by Observer
Tue Jan 08, 2008 1:33 pm
Forum: Volume 113 (11300-11399)
Topic: 11376 - Tilt!
Replies: 40
Views: 9049

I have received mf's code. I check it with the i/o set I sent to the admins and it gives correct answers! :-?
by Observer
Tue Jan 08, 2008 11:22 am
Forum: Volume 113 (11300-11399)
Topic: 11376 - Tilt!
Replies: 40
Views: 9049

Yes, I have sent them a new set of input/output, but I suppose they haven't had this task rejudged yet? When I get home I will see if I have sent them a correct i/o set. By the way, can any of you send me your should-be-correct codes, so that I can use them to check if input file is indeed correct o...
by Observer
Fri Jan 04, 2008 3:34 pm
Forum: Volume 113 (11300-11399)
Topic: 11376 - Tilt!
Replies: 40
Views: 9049

I think it is about time for me to change the test cases a bit. As you may guess the 53-step maze mentioned in previous posts can be found in the judge input. :D So I think I need to change the input file so future solvers cannot cheat.
by Observer
Thu Jan 03, 2008 2:03 pm
Forum: Volume 113 (11300-11399)
Topic: 11373 - Happy Birthday
Replies: 16
Views: 3909

If you fail to get anything from your drawings then I don't know what hints I can give, since it seems that you don't even know what you are trying to compute... I think you should at least try to work out mitsiddharth's sample by hand (and calculator). Otherwise I am afraid that no hint will be use...
by Observer
Thu Jan 03, 2008 7:05 am
Forum: Volume 113 (11300-11399)
Topic: 11373 - Happy Birthday
Replies: 16
Views: 3909

If you have absolutely no idea where to start, try drawing some cases on paper. I think you should at least know how to compute the areas on paper......
by Observer
Wed Jan 02, 2008 7:01 am
Forum: Volume 113 (11300-11399)
Topic: 11376 - Tilt!
Replies: 40
Views: 9049

I don't have a BFS judge solution. But I think heuristic search is not so hard to code for this problem. And such an idea is also not hard to come up with. Of course, to get a better timing for this particular problem, you can add the heuristic function to your BFS, since it is given that you won't ...
by Observer
Wed Jan 02, 2008 6:15 am
Forum: Bugs and suggestions
Topic: 11373 - Happy Birthday
Replies: 4
Views: 2100

Yes... Actually even in the new input set, no points given in the input are in the interior of the cake (circle), and each line segment really makes a cut. :P

Shall I add that in the problem description?
by Observer
Mon Dec 31, 2007 11:08 am
Forum: Volume 113 (11300-11399)
Topic: 11374 - Airport Express
Replies: 15
Views: 6571

Test cases are not generated by me. The only tricky case that I know is that the starting location is the airport.

Go to advanced search