Title |
User |
Message |
Date Posted |
Memory Limits |
spencereir |
Memory is _very_ strict on this problem. If you are solving it in C/C++, make sure you use short int or char to store the map, using int will MLE (It did for me, anyway) |
Dec 13, 2015 - 3:18:16 am UTC |
Re: Re: Re: Re: Re: Re: ... |
platynumplatypus |
maybe we should get rid of these comments cus they kind of give away the answer... |
Feb 11, 2009 - 2:18:49 am UTC |
Re: Re: Re: Re: Re: ... |
bleung91 |
The start point must have three 'X' surrounding it, no more no less and anything beyond that has two 'X'. That's what I did. |
Feb 11, 2009 - 1:51:14 am UTC |
Re: ... |
SourSpinach |
Basically, a niche always stops one square BEFORE a fork (which should be clear from the example...). You can pretend that the paper is surrounded by empty squares, so the reason a niche can never go... |
Feb 10, 2009 - 11:38:25 pm UTC |
Re: Re: Re: Re: ... |
platynumplatypus |
so basically you always need at least two sides of 'X's surrounding your cell...?? |
Feb 10, 2009 - 11:35:19 pm UTC |
Re: Re: Re: ... |
bbi5291 |
I'm guessing that the fork itself is not included in the niche, but all squares "before" it are included, that would resolve the issue... |
Feb 10, 2009 - 11:27:53 pm UTC |
Re: Re: ... |
platynumplatypus |
but thats what i'm saying. in the example they give, the niche stops when it shouldn't have because it hasn't reached a fork or the edge of the paper. |
Feb 10, 2009 - 11:21:11 pm UTC |
Re: ... |
Saravannan |
while all the others lead from it to a fork (or to the edge of the paper) I guess it's because it reaches the end of the page? |
Feb 10, 2009 - 10:55:57 pm UTC |
... |
platynumplatypus |
Question. In the example you gave. Look at the niche with asterisks. X@XX X XXXXX XXXXX*X XXX@@ X XX*X @X@@X XXXXXXX XXXXX Shouldn't it continue and look something like this? X@XX *X XXXXX XXXXX*X... |
Feb 10, 2009 - 10:30:55 pm UTC |
Hint |
SourSpinach |
There isn't too much to say about this problem - you don't need a fancy solution to do it. Just notice that every niche "starts" at a dead end, so if you found all the dead ends and followed each one... |
Dec 05, 2008 - 1:51:32 am UTC |