crd = list(range(1, list(map(int, input().split()))[0] + 1)) chg = list(map(int, input().split())) for i in range(len(chg)): for j in reversed(range(1, chg[i])): crd[j], crd[j - 1] = crd[j - 1], crd[j] print(crd[0])