C:Added knapsack example.