Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 1063ce2

Browse files
authored
Sri Hari: Batch-5/Neetcode-ALL/Added-articles (#3822)
* Batch-5/Neetcode-ALL/Added-articles * Batch-5/Neetcode-ALL/Added-articles * Batch-5/Neetcode-ALL/Added-articles
1 parent 332199e commit 1063ce2

24 files changed

+10167
-132
lines changed

articles/binary-tree-from-preorder-and-inorder-traversal.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -240,11 +240,11 @@ class Solution {
240240
### Time & Space Complexity
241241

242242
* Time complexity: $O(n ^ 2)$
243-
* Space complexity: $O(n ^ 2)$
243+
* Space complexity: $O(n)$
244244

245245
---
246246

247-
## 2. Hash Map
247+
## 2. Hash Map + Depth First Search
248248

249249
::tabs-start
250250

@@ -780,4 +780,4 @@ class Solution {
780780
### Time & Space Complexity
781781

782782
* Time complexity: $O(n)$
783-
* Space complexity: $O(n)$
783+
* Space complexity: $O(n)$ for recursion stack.

0 commit comments

Comments
 (0)