📅  最后修改于: 2022-03-11 14:45:21.447000             🧑  作者: Mango
Testing for the presence of a number in a set is fast in Python so you
could try something like this:
def minpositive(a):
A = set(a)
ans = 1
while ans in A:
ans += 1
return ans