def main(): S, t, u = input().split() S = list(S) if t == u: S.pop(int(t)) else: S.pop(int(min(t,u))) S.pop(int(max(t,u))-1) print(''.join(S)) if __name__ == '__main__': main()