print k node tree

there are two classes in it.