Refactored printing of parse tree, now prints values as well as tree structure. modified test case