I found a good online Ruby regular editor, the address is http://www.rubular.com/
please see below pictures.