re: Knapsack problem algorithms for my real-life carry-on knapsack VIEW POST

FULL DISCUSSION
 

Great article! introduced me to dynamic programming.

Sorry to be nitpicking - rows and columns should be interchanged in this statement -

"Create a matrix representing all subsets of the items (the solution space) with columns representing items and rows representing the bag's remaining weight capacity"

 

Congratulations, you've passed the secret hidden test and won a prize!

Seriously though good catch! I must have missed that several times. Guess you're the only one who read the article. :)

Thank you!

 

The topic was dense to me and I am unknown to Go syntax, so I was reading slowing over several days and thinking about it :P

code of conduct - report abuse