Added a knapsack solver with tests.