Moved tree print utility to builder class.
Added an example.