Groovy web console

subscribe to the feed Subscribe
to this
site

Untitled

Published 4 months ago by Anonymous
Actions Execute script  ▶ Edit in console Back to console Show/hide line numbers View recent scripts
def arr = ['foo', 'bar', 'baz']
def arrString = arr.toString()

def newArr = arrString.tokenize(',[]').collect {it.trim()}

newArr.forEach {println(it)}