Skip to content
phraemer edited this page Sep 13, 2010 · 11 revisions

Hello reader!

This is my first attempt at a full program in Clojure.
It’s a simple boggle solver (that doesn’t take into account the letter Qu from the real game)

After so many years of programming in c++ it took me some time to get my head around approaching the problem in a functional way like this but I found it an excellent exercise to help me learn Clojure.

Most surprising was how easily data structures such as tries can be represented in Clojure.

I would love to hear comments regarding how to make it more idiomatic.
I’m sure it could be greatly improved and it might make an interesting example for others learning the language to see different versions.

I’d also like to hear comments on how to improve the speed.

James

Some speed analysis….

2.4 GHz Core 2 Duo running OSX 10.6.1
Clojure 1.1.0-alpha-SNAPSHOT
Java™ SE Runtime Environment (build 1.6.0_15-b03-219)
Java HotSpot™ 64-Bit Server VM (build 14.1-b02-90, mixed mode)

java -server

Profiled with a modified version of the standard time macro

Clone this wiki locally