ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1526. Martian Plates

Question about worktime
Posted by Igor E. Tuphanov 24 Feb 2007 14:25
How do you think, is 1000*100*100*10 - solution quite normal? Or is there a faster solution? I've got AC with time above, but it take me some time to fit TL.
Re: Question about worktime
Posted by Kit 24 Feb 2007 18:01
My solution has same complexity, but it works fairly fast.
Re: Question about worktime
Posted by svr 26 Aug 2007 10:37
It's interesting to recognize professional secrets.
I think,that here 1000=1024=2^10 and means DP on
subsets of admissible plates.
First 100- is number of ways to remove first stage of fiesta:when first stack of plates go up and disappeare after.
Second 100- Dp when calculating number of ways to build the fist stack of plates as a function of it's height<=100.
And final 10- innerst loop op Dp then one of 10 plates
may be pushed to head of stack(stack here not programming but fiesta's term)

Edited by author 26.08.2007 10:38

Edited by author 26.08.2007 10:38
Re: Question about worktime
Posted by Denis Koshman 6 Aug 2008 02:43
Actually it's not quite 1000*10 if optimized properly. Either 1000 decreases by considering only dishes within uncommon pairs or 10 decreases according to number of dishes affectable by current value of 2^10 loop. It even can become 2000 or smth like that.

Edited by author 06.08.2008 02:43