class Problem0292: def solve(this): s,t,u = input().split() res = [item for idx, item in enumerate(s) if idx != int(t) and idx != int(u)] print(''.join(res)) if __name__ == "__main__": problem = Problem0292() problem.solve()