mirror of
https://github.com/donnemartin/interactive-coding-challenges
synced 2026-01-03 16:08:02 +00:00
Simplified challenge coding and unit tests by working with the node directly as opposed to node.id or node.data, which is more natural when writing coding challenges.
This commit is contained in:
@@ -98,7 +98,7 @@
|
||||
" queue.append(root)\n",
|
||||
" while queue:\n",
|
||||
" node = queue.popleft()\n",
|
||||
" visit_func(node.data)\n",
|
||||
" visit_func(node)\n",
|
||||
" if node.left is not None:\n",
|
||||
" queue.append(node.left)\n",
|
||||
" if node.right is not None:\n",
|
||||
|
||||
Reference in New Issue
Block a user