Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

7
Highest summation that fits within a threshold?
Post Body

Greetings all,

I am just curious if there is an existing algorithm that determines a summation of elements that fit within a threshold.

For example:

If we have an array of {9, 6, 7, 4, 13} and want a combination of those to be summed and be less than or equal to 26. However, we want the sum as close to 26 as possible.

Does an algorithm like this exist? Thanks in advance :)

Author
Account Strength
50%
Account Age
2 years
Verified Email
Yes
Verified Flair
No
Total Karma
109
Link Karma
52
Comment Karma
32
Profile updated: 4 days ago
Posts updated: 10 months ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
2 years ago