Groovy web console

subscribe to the feed Subscribe
to this
site
keySet on empty map (via #groovywebconsole)
tweet this snippet Tweet
this
script

keySet on empty map

Published 1 month ago by Anonymous
Actions  ➤ Edit in console Back to console Show/hide line numbers View recent scripts
println("map with keys: " + ["a":2].keySet().asList().join(","))
println("map with no keys: " + [:].keySet().asList().join(","))