剑指offer python版 0到n-1中缺失的数字 def aa(nums,n): for i in range(n): if i ==nums[i]: i +=1 else: return i print(aa([0,1,2,3,4,5,7],8))