[Haskell-beginners] Fast tree manipulation