arr.sort(reverse=True) for i in range(len(arr)): pass. 因为要先排序,再循环,所以效率会比较低。 这里不讨论Python内置函数sorted(),它的效率 ...
確定! 回上一頁