import sequtils, strutils let s = readLine stdin ns = stdin.readLine.split.map parseInt i = ns[0] j = ns[1] var result = s result[i] = s[j] result[j] = s[i] echo result