MaxMinSwap by leonid

loop{a=eval gets
s=a.sort
i=0
a.map{a[a.index(s[i])]=s[~i].to_s;i= ~i-i/9}
puts"[#{a*','}]"}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return top