A Groovy solution for the Ninth Annual ICFP <http://www.boundvariable.org/task.shtml> by Jim White.