bookmark

Array of strings in groovy - Stack Overflow


Description

If you really want to create an array rather than a list use either

String[] names = ["lucas", "Fred", "Mary"]

or

def names = ["lucas", "Fred", "Mary"].toArray()

Preview

Tags

Users

  • @jil

Comments and Reviews