# worksa = [2, 1, 3]a.sort! # notice the !print a #doesn't worka = "symbols"a.to_sym! # notice the !print a
Standard input is empty
[1, 2, 3]
prog.rb:8:in `<main>': undefined method `to_sym!' for "symbols":String (NoMethodError)
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!