a={[int(i) for i in input().split()]} b={i for i in range(1,11)} c =b-a print(list(c)[0])