Problems requiring a greedy approach can be solved using the following template: n = 5, a=[a1,a2,a3,a4,a5] algorithm greedy(a,n): for i = 1 to n: x ...
確定! 回上一頁