mirror of
https://github.com/donnemartin/interactive-coding-challenges
synced 2026-01-03 07:58:02 +00:00
Update bst validate challenge (#115)
Change Exception to the more specific TypeError.
This commit is contained in:
@@ -120,7 +120,7 @@
|
||||
"\n",
|
||||
" def validate(self):\n",
|
||||
" if self.root is None:\n",
|
||||
" raise Exception('No root node')\n",
|
||||
" raise TypeError('No root node')\n",
|
||||
" return self._validate(self.root)\n",
|
||||
"\n",
|
||||
" def _validate(self, node, mininum=-sys.maxsize, maximum=sys.maxsize):\n",
|
||||
|
||||
Reference in New Issue
Block a user