s=list(input()) i,j=list(map(int,input().split())) a=s[i] b=s[j] s[i]=b s[j]=a print(''.join(s))