public IEnumerable <IBinaryTreeNode <TItem> > TraverseInorder() { var nodes = new List <IBinaryTreeNode <TItem> >(); nodes.Add(this); if (LeftNode != null) { nodes.AddRange(LeftNode.TraverseInorder()); } if (RightNode != null) { nodes.AddRange(RightNode.TraverseInorder()); } return(nodes); }