結果 : define greedy method explain about knapsack problem with an example