Skip to content

Instantly share code, notes, and snippets.

@BenHall
Created December 5, 2009 17:14
Show Gist options
  • Save BenHall/249766 to your computer and use it in GitHub Desktop.
Save BenHall/249766 to your computer and use it in GitHub Desktop.
s = "test 'a' and 'b' and 'c'"
arguments = s.scan /'\w+'/
=> ["'a'", "'b'", "'c'"]
a.join ', '
=> "'a', 'b', 'c'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment