Groovy web console

subscribe to the feed Subscribe
to this
site

Check string suffix

Published 2 years ago by vmj
Actions Execute script  ▶ Edit in console Back to console Show/hide line numbers View recent scripts
final suffix = "12345"
final s = "abc12345"
final b = s.endsWith(suffix)

println b