Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Mathematics knundrum
Message
From
24/04/2003 14:42:13
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00780672
Message ID:
00781245
Views:
38
I was trying to think of a way to short circuit the loops once the sum of a group of numbers exceeds the target value...

And if the numbers are sorted numerically, there is no reason to start a loop for any numbers greater than half of the target value. But of course, if there is a solution, it would be found by that time.

But I haven't studied Jay's algorithm, so I don't know how this could be implemented...

Any thoughts, Jay?

>Hi Steve, no negative numbers. Actually the first thing I do is delete all records less than or equal to 0 and all numbers greater than the Target to help narrow the field. -Marvin
>
Steve Gibson
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform