Added Node and VarTree structure for sorting.