We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3249f63 commit a3ccacaCopy full SHA for a3ccaca
javascript/0144-binary-tree-preorder-traversal.js
@@ -16,7 +16,7 @@
16
var preorderTraversal = function(root) {
17
18
const dfs = (node, pre) => {
19
- if(!node) return pre;
+ if (!node) return pre;
20
pre.push(node.val);
21
dfs(node.left, pre);
22
dfs(node.right, pre);
0 commit comments