11126 - Relaxed Golf

All about problems in Volume 111. If there is a thread about your problem, please use it. If not, create one with its number in the subject.

Moderator: Board moderators

Post Reply
luishhh
New poster
Posts: 26
Joined: Mon Oct 25, 2004 8:11 pm
Location: Spain

11126 - Relaxed Golf

Post by luishhh » Mon Oct 16, 2006 8:09 pm

Few people have solved this problem. I am using only backtracking with memoization, could it be enough? I keep getting WA, time: 3.3 seconds. This time would be the best in the ranklist, that's why I hesitate if my implementation has a bug or my entire approach to the problem is non-sense.
"From lost to the river" --> Spanish quote

sunny
Experienced poster
Posts: 124
Joined: Sun Sep 11, 2005 10:22 pm
Location: Civil-BUET

Post by sunny » Mon Oct 16, 2006 8:53 pm

i am trying 2 do it with the same approach but having problem with the memory.

if i use 13*5*5*5*5*5*5*5*17 memory it's RE.
but i believe my program is fine for memory of 13*6*6*6*6*6*6*6*18.
but gets MLE.

User avatar
little joey
Guru
Posts: 1080
Joined: Thu Dec 19, 2002 7:37 pm

Post by little joey » Mon Oct 16, 2006 9:10 pm

I think that during the contest the memory limit was 64MB, so a 6^6*13*17 array of char could be used. But now the limit is only 32 MB. However you can store one dimension in six bits of the char, so a 6^5*13*17 array of char is enough (the last dimension can be 17, because you always put the first card on the discard pile).

sunny
Experienced poster
Posts: 124
Joined: Sun Sep 11, 2005 10:22 pm
Location: Civil-BUET

Post by sunny » Tue Oct 17, 2006 7:59 am

got AC.
Last edited by sunny on Tue Oct 17, 2006 2:36 pm, edited 1 time in total.

sclo
Guru
Posts: 519
Joined: Mon Jan 23, 2006 10:45 pm
Location: Vancouver, BC, Canada
Contact:

Post by sclo » Tue Oct 17, 2006 9:46 am

I keep getting TLE, I think that the time limit might be too tight for this problem.
I see that they've finally increased the memory limit, although I have already derived ways to do it with less than 17MB

Post Reply

Return to “Volume 111 (11100-11199)”