Skip to content

Instantly share code, notes, and snippets.

@samaaron
Created January 27, 2009 10:24
Show Gist options
  • Select an option

  • Save samaaron/53270 to your computer and use it in GitHub Desktop.

Select an option

Save samaaron/53270 to your computer and use it in GitHub Desktop.
List join = method(
"returns a string created by converting each element of the array to text, separated by an optional separator",
separator "",
self[0..-2] inject("", sum, x, sum + x asText + separator) + self[-1] asText)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment