Minor fixes to knapsack example