Groovy web console

subscribe to the feed Subscribe
to this
site

Filter a list

Published 2 years ago by Andy Duncan with tags collections
Actions Execute script  ▶ Edit in console Back to console Show/hide line numbers View recent scripts
def p = { it > 2 }
def x = [1, 2, 3]
def y = x.findAll(p)