首页 › 答案 › 题库 › 远程教育 › 联大学堂

编写函数,模拟Python内置函数sorted()。

编写函数,模拟Python内置函数sorted()。
正确答案:defSorted(v):t=v[:]r=[]whilet:tt=min(t)r.append(tt)t.remove(tt)returnr