Leisure implementation of the ICFP contest 2006