from pprint import pprint def main(): s=input() i,j=map(int,input().split()) l=[] for k in range(len(s)): l.append(s[k]) tmp=l[i] l[i]=l[j] l[j]=tmp print(*l,sep="") if __name__ == "__main__": main()