knapsack.py