Home | Notes | Languages | Programs | Homework |
Re: fact placement |
Stephen Edwards (edwards@CS.VT.EDU)
Sun, 11 Nov 2001 21:12:09 -0500
Message-ID: <3BEF2FF9.ADE9F348@cs.vt.edu> Date: Sun, 11 Nov 2001 21:12:09 -0500 From: Stephen Edwards <edwards@CS.VT.EDU> Subject: Re: fact placement
> If we have found a valid solution are we allowed to optimize our code so
> that it takes the least amount of time to guess the solution?
That is unnecessary, since the Curator will only check to see if your
solution runs within the given limits. There is no bonus for "fastest"
program.
I have not yet spoken to anyone whose solution is "close to the wire"
in terms of execution time--either it runs in a few seconds, or it
takes way too long.
While reordering facts or rules is perfectly OK, the biggest speedup
is more likely to be gained by reordering clauses within your
house_solution predicate. For example, if you guess all nationalities
first, followed by all pets, you can then screen against all the
clues that depend only on those two dimensions of the solution before
you start guessing more variables. If you next guess drinks, say, then
you can filter against all clues involving any of the 3 dimensions you
have guessed so far. If you're really clever, you can work out which
clues depend on which dimensions, and try to guess the dimensions in
an order which maximizes your ability to filter against clues as early
as possible.
> How is the curator going to handle this?
The Curator just checks that your output is correct, and that it is
produced within the allowable time.
While reordering of facts or rules is perfectly OK, hardcoding in
parts of the solution is not. Hardcoding in which combinations
match a particular clue (or set of clues) is also not acceptable.
-- Steve
-- Stephen Edwards 604 McBryde Hall Dept. of Computer Science e-mail : edwards@cs.vt.edu U.S. mail: Virginia Tech (VPI&SU) office phone: (540)-231-5723 Blacksburg, VA 24061-0106 -------------------------------------------------------------------------------
Home | Notes | Languages | Programs | Homework |