def qsort(l):
if len(l)==1:return l
n=l[0]
a=0
b=len(l)-1
while(a<b):
while(a<b and l[a]<=n):a+=1
while(a<b and l[b]>=n):b-=1
l[a],l[b]=l[b],l[a]
if l[0]>l[a]:l[a],l[0]=l[0],l[a]
return qsort(l[:a])+qsort(l[a:])
面试时脑子抽了,居然 忘了改变l[:a]不能改变l