贪心法

greedy method