From: Tobias Reif Date: 2001-10-24T23:31:08+09:00 Subject: [ruby-talk:23196] Re: Bruce Eckel's opinion of Ruby Michael Neumann wrote: > More technically: > s/re// is a Perl regular expression, substituting "re" with "". > In Ruby you would say instead: > > # $_ = "...reinventing" > sub(/re/, //) > # puts C:\>ruby -e 'print "reinventing".sub!(/re/,//)' #inventing C:\>ruby -e 'print "reinventing".sub!(/re/,"")' inventing ;) Tobi -- Tobias Reif http://www.pinkjuice.com/myDigitalProfile.xhtml go_to('www.ruby-lang.org').get(ruby).play.create.have_fun http://www.pinkjuice.com/ruby/