A* in Haskell as a learning exercise.