Fix bst challenge time complexity discussion (#135)

This commit is contained in:
Donne Martin 2017-01-05 22:59:15 -05:00 committed by GitHub
parent 3d49bb1d43
commit 7945ec045d

View File

@ -84,7 +84,7 @@
"Complexity:\n", "Complexity:\n",
"\n", "\n",
"* Time: O(h), where h is the height of the tree\n", "* Time: O(h), where h is the height of the tree\n",
" * In a balanced tree, the height is O(nlogn)\n", " * In a balanced tree, the height is O(log(n))\n",
" * In the worst case we have a linked list structure with O(n)\n", " * In the worst case we have a linked list structure with O(n)\n",
"* Space: O(m), where m is the recursion depth, or O(1) if using an iterative approach" "* Space: O(m), where m is the recursion depth, or O(1) if using an iterative approach"
] ]