[quiz] Anybody there?

Ivan Salazar ivan.salazarv at gmail.com
Wed Jul 11 03:35:45 UTC 2007


2007/7/9, Ryan Davis <ryan at acceleration.net>:
>
>  How about the problem in today's XKCD?: http://xkcd.com/c287.html
>
> Ryan Davis
> Acceleration.net
> Director of Programming Services
> 2831 NW 41st street, suite B
> Gainesville, FL 32606
>
> Office: 352-335-6500 x 124
> Fax: 352-335-6506
>
>
>
> Ivan Salazar wrote:
>
> It sounds interesting. I'd like to join in, even if I'm a real newbie.
> Have you got any ideas?
>
> ------------------------------
>
> _______________________________________________
> quiz mailing list
> quiz at common-lisp.nethttp://common-lisp.net/cgi-bin/mailman/listinfo/quiz
>
>
> _______________________________________________
> quiz mailing list
> quiz at common-lisp.net
> http://common-lisp.net/cgi-bin/mailman/listinfo/quiz
>
> OK... This is the second time I've heard of the knapsack problem. I've
searched a little and I have some questions:
 - Are repetitions allowed (one kind of appetizer chosen more than once)?
 - Should we maximize or minimize the number of appetizers?
If I were the waiter, it wouldn't matter if I chose an appetizer more than
once but I'd try to carry less appetizers.
If I were the costumer, I'd like a diverse mix (no repetitions) and more
appetizers.

I'm thinking about programming a more general algorithm, something like
this:

(defun serve-appetizers (menu amount &key (:with-reps nil) (:minimize t))
  ;... lots of code

I have to do more research obviously (maybe it isn't feasible to program
such thing, I don't now).
Have you got any particular idea or solution?
Iván.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/quiz/attachments/20070710/41368cfa/attachment.html>


More information about the Quiz mailing list