Wrote a jig as well; feedback welcomed!