s, *T = input().split() t, u = map(int, T) if t == u: print(s[:t] + s[t + 1:]) else: if t > u: t, u = u, t print(s[:t] + s[t + 1:u] + s[u + 1:])