eval'N,*A='+$<.read.split*?, $><N-2&&next;A[a]>(c=A[b])&&(A[b]=A[a];A[a]=c)}} $><