Search found 63 matches

by Christian Schuster
Fri Jun 12, 2009 11:54 am
Forum: Bugs and suggestions
Topic: Special Corrector Problem - Always PE
Replies: 10
Views: 4750

Re: Special Corrector Problem - Always PE

Is this issue really solved? I keep getting PE on problem 11599.
by Christian Schuster
Sun Jun 01, 2008 2:18 pm
Forum: Volume 114 (11400-11499)
Topic: 11454 - Very well informed domino player
Replies: 9
Views: 3111

Re: 11454 - Very well informed domino player

Hi, my result for (0,2) matches LayCurse's. My "wins" values are: (0,3)/(3,0): 22401389 (1,1): 11018156 (3,4)/(4,3): 24849438 (1,5)/(5,1): 9158932 (0,2)/(2,0): 13322980 (0,6)/(6,0): 21685496 (4,6)/(6,4): 20858993 Also, the problem statement is unclear about ties. Should they be considered in "loses"...
by Christian Schuster
Fri Jan 25, 2008 12:54 am
Forum: Volume 113 (11300-11399)
Topic: 11399 - What be thy Name, O Dear Tree?
Replies: 0
Views: 1371

11399 - What be thy Name, O Dear Tree?

Hi there, the problem states that there are "up to 500 symbols from V and only from V" - but my parser failed on the judge's input, just because it included an "assert(0);" if it read an invalid character. Simply ignoring those invalid characters got me AC. BTW: The last sample case also contains an...
by Christian Schuster
Mon Mar 26, 2007 1:10 am
Forum: Volume 3 (300-399)
Topic: 354 - Crazy Calculator
Replies: 15
Views: 7325

I didn't yet solve this one, but IMHO two operators with the same precedence must have the same associativity. In your input, this is not the case with * and /. Imagine the expression 2*2/3, using the precedences and associativities from your input. It could be evaluated to (2*2)/3 = 1 or to 2*(2/3)...
by Christian Schuster
Mon Nov 13, 2006 2:55 am
Forum: Volume 111 (11100-11199)
Topic: 11111 - Generalized Matrioshkas
Replies: 19
Views: 10613

A hint for the C people getting TLE:

sscanf() on long input strings is extremely slow, because the glibc implementation of this function scans the string for the terminating \0 character. Using strtok() or something like that is much faster in this problem.
by Christian Schuster
Thu Mar 09, 2006 6:53 pm
Forum: Volume 104 (10400-10499)
Topic: 10438 - Meta Editor
Replies: 17
Views: 11313

I just tried to solve this beast once again and came to the conclusion that the order of elimination does matter! This happens when I repeatedly try to eliminate with length=max..1, scanning from left to right: b a b a c a c b a b c b a c b a b c a c b a c b a b a c a b a>b a b a c a b a<c b b a b a...
by Christian Schuster
Mon Dec 12, 2005 12:18 am
Forum: Volume 8 (800-899)
Topic: 888 - Donkey
Replies: 5
Views: 4809

888 - Donkey

Hello folks. This problem seemd quite simple to me: Some backtracking+memoization (or DP) should be sufficient. However, I got a bunch of WAs within times comparable to the AC solutions. My solution uses the tuple of distances to the capital as memoization key. As I don't think my calculations are p...
by Christian Schuster
Thu Dec 08, 2005 2:42 pm
Forum: Volume 104 (10400-10499)
Topic: 10417 - Gift Exchanging
Replies: 12
Views: 5464

More than one year since the last post - let me revive that one! :D I finally got this one AC after lots of WAs. The essential point is not to write "1 0.251" when you could write "2 0.251". Personally, I think this is misleading and incorrect, as box 1 with a value of 0.2514 is definitely a better ...
by Christian Schuster
Fri Dec 02, 2005 5:26 pm
Forum: Volume 109 (10900-10999)
Topic: 10927 - Bright Lights
Replies: 26
Views: 13413

@Pier:

Your test if a pole is visible is wrong. A pole occludes all poles having the same angle, a greater distance and at most the same size.

HTH,
Christian
by Christian Schuster
Thu Nov 10, 2005 3:27 pm
Forum: Volume 108 (10800-10899)
Topic: 10838 - The Pawn Chess
Replies: 11
Views: 4587

Thank you. I had alpha-beta pruning enabled in my code, but this does not work if values are changed when passing them up the game tree. Something like this is necessary for the "fast victory/slow defeat" strategy to work.

Finally, I got AC in 2.38s using "normal" minimax.
by Christian Schuster
Wed Nov 09, 2005 5:06 pm
Forum: Volume 108 (10800-10899)
Topic: 10838 - The Pawn Chess
Replies: 11
Views: 4587

I tried to solve this problem by using a minimax search. Each game state is assigned a value recursively: 0 <= N <= 19: BLACK wins after N moves 20 <= N <= 39: WHITE wins after (39-N) moves Winning states get a 0 or 39, depending on the winner. For any other game state, BLACK uses the child state wi...
by Christian Schuster
Mon May 09, 2005 10:00 am
Forum: Volume 4 (400-499)
Topic: 473 - Raucous Rockers
Replies: 16
Views: 7318

It's not allowed to put songs 1 and 3 on disk 1 and song 2 on disk 2. More formally, for every possible pair (a,b) of chosen song numbers having a>b, the relation disk(a)>=disk(b) must hold.
by Christian Schuster
Mon Feb 21, 2005 2:05 am
Forum: Volume 100 (10000-10099)
Topic: 10073 - Constrained Exchange Sort
Replies: 14
Views: 4472

Ermmm... "0:00.1000" seems to be a quite strange time. ;)
by Christian Schuster
Sun Feb 20, 2005 9:31 pm
Forum: Volume 100 (10000-10099)
Topic: 10073 - Constrained Exchange Sort
Replies: 14
Views: 4472

The problem can be interpreded as a three-dimensional version of the 15 Puzzle. A---D /| /| B---E | /| G/|-J C---F |/ | H-|-K |/ |/ I--- Possible exchanges are nothing but movements of letters to the (empty) "L" field. Using an IDA* search with the manhattan heuristics for the 15 Puzzle, my solution...
by Christian Schuster
Sun Feb 20, 2005 7:57 pm
Forum: Volume 8 (800-899)
Topic: 868 - Numerical Maze
Replies: 21
Views: 14303

No, you may not use a grid cell twice. At least I got AC with that assumption. ;)

Go to advanced search