[Tutor] Algorithm Question

Kirby Urner urnerk@qwest.net
Wed, 09 Jan 2002 06:59:52 -0800


At 03:42 PM 1/9/2002 +0100, Remco Gerlich wrote:
>On  0, Kirby Urner <urnerk@qwest.net> wrote:
> > I modified this to sort the output, and gave it:
> >
> >    >>> sums([5,11,15])
> >
> > and got:
> >
> > [31, 36, 41, 42, 46, 47, 51, 52, 53, 56, 57, 58, 61, 62,
> > 63, 64, 66, 67, 68, 69, 71, 72,
> >
> > etc. etc.
> >
> > but shouldn't 5 + 2*15 = 30 be on the list?  I confess
> > I never understood Daniel's description of what he needed
> > very well.

Sorry, I goofed, I meant 5 + 2*15 = 35.  Shouldn't 35 be
present?

>My interpretation is that all numbers from the list must be present in the
>sum, since they can be multiplied by 1 to 10, not 0. Therefore the lowest
>number is 31=5+11+15.


Kirby