title: Return smaller values in a BST inorder
body: <p>I am trying to implement this method, &quot;smaller&quot; for a BST, that returns the values in the tree which are smaller than a given item, in order.</p>
  <pre><code>class BinarySearchTree:
      def __init__(self, root: Optional[Any]) -&gt; None:
          if root is None:
              self._root = None
              self._left = None
              self._right = None
          else:
              self._root = root
              self._left = BinarySearchTree(None)
              self._right = BinarySearchTree(None)
  
      def is_empty(self) -&gt; bool:
          return self._root is None
  
      def smaller(self, item: Any) -&gt; List:
          if self.is_empty():
              return []
          else:
              return self._left.items() + [self._root] + self._right.items()
  </code></pre>
  <p>So far, the &quot;smaller&quot; method will return all of the values in the tree in order, but I'm not sure how to check if those values are smaller and than a given item, and to only return those in a list.</p>