a=input() for i in range(1,11): if str(i)in a: continue else: print(i)