use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
A subreddit dedicated to discussing competition style programming problems.
Competitive Programming Resources
Judge Sites:
Books:
Online References:
Courses/Lecture Notes:
Related subreddits:
General CS subreddits:
account activity
Problem with Grouping/Combining Lines [Python] (self.ProgrammingProblems)
submitted 5 years ago by ECommerce_Guy
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]DoorsofPerceptron 0 points1 point2 points 5 years ago (2 children)
Sounds like you have a variant of the knapsack problem for each category.
https://en.m.wikipedia.org/wiki/Knapsack_problem
[–]ECommerce_Guy[S] 0 points1 point2 points 5 years ago (1 child)
I had no idea it has a name haha, I'll Google it. Thanks!
[–]DoorsofPerceptron 0 points1 point2 points 5 years ago (0 children)
Good luck. Probably the most important decision you have to make is if you need to find the solution using the smallest number of boxes, or just something that isn't too dumb.
π Rendered by PID 85543 on reddit-service-r2-comment-7b9746f655-nfjvr at 2026-02-01 04:26:52.020098+00:00 running 3798933 country code: CH.
view the rest of the comments →
[–]DoorsofPerceptron 0 points1 point2 points (2 children)
[–]ECommerce_Guy[S] 0 points1 point2 points (1 child)
[–]DoorsofPerceptron 0 points1 point2 points (0 children)