class Fixnum def <=>(i) i.to_s<=>self.to_s endend p [50, 2, 1, 9].sort.join
Standard input is empty
"95021"
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!