parameters: (self, data)
docstring: inserts new integer data into the tree at the position, so that
              the binary search tree property is maintained.
docstring_summary: inserts new integer data into the tree at the position, so that
              the binary search tree property is maintained.
docstring_tokens: inserts new integer data into the tree at the position so that the binary search tree property is maintained .
function: def insert(self, data):
          """ inserts new integer data into the tree at the position, so that
              the binary search tree property is maintained.
          """
          def _insert(root, data):
              """ recursive internal method which works on node level """
              if root is None:
                  root = Node(data)
              elif data <= root.data:
                  root.left = _insert(root.left, data)
              else:
                  root.right = _insert(root.right, data)
              return root
  
          if self.root is None:
              self.root = Node(data)
          else:
              self.root = _insert(self.root, data)
function_tokens: def insert ( self , data ) : def _insert ( root , data ) : """ recursive internal method which works on node level """ if root is None : root = Node ( data ) elif data <= root . data : root . left = _insert ( root . left , data ) else : root . right = _insert ( root . right , data ) return root if self . root is None : self . root = Node ( data ) else : self . root = _insert ( self . root , data )