Wes wrote:
> On Oct 26, 11:59�am, Alpha Blue <[email protected]>
> wrote:
>> �win_loss = "#{myvars[i].scan(/\w\s\d{1,2}-\d{1,2}/)}"
> You can also do:
>
> myvars[i].scan(/\w\s\d{1,2}-\d{1,2}/).to_s
Excellent point. If you're #{interpolating} the whole string, you might
just as well use the expression without quotes.
>
> It will do the right thing when no match is found, etc.
>
> -- W
Best,
--
Marnen Laibow-Koser
http://www.marnen.org
[email protected]
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---