n = 24987654puts n / (10 ** (n.size - 2)) * (10 ** (n.size - 2))
Standard input is empty
24987600
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!