Skip to content

Instantly share code, notes, and snippets.

@sahid
Last active December 13, 2015 21:48
Show Gist options
  • Save sahid/4979320 to your computer and use it in GitHub Desktop.
Save sahid/4979320 to your computer and use it in GitHub Desktop.
Search min/max in a BST. Python
def min(node):
while node.left:
node = node.left
return node
def max(node):
while node.right:
node = node.right
return node
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment