Hello , I can't realize why the judge output is much strange !!! problem link : http://mirror.codeforces.com/contest/451/problem/B
my code : https://paste.ubuntu.com/25939858/
judge status : http://mirror.codeforces.com/contest/451/submission/32225322
in my compiler , answer is okay , but where is the problem ?? I have also tested in different online compilers also
Auto comment: topic has been updated by Ahnaf.Shahriar.Asif (previous revision, new revision, compare).
See, the problem is that you have to print the indicies of the elements to be swapped, not the elements themselves. You are printing elements instead.
but I am printing minimum first , and then the maximum , that is the swapped numbers , why it is printing "1 2" ???
I am sorry , you were right