Skip to content

Commit 9ccd8df

Browse files
authored
Update Fibonacci Number - Leetcode 509.cpp
1 parent 473051a commit 9ccd8df

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Fibonacci Number - Leetcode 509/Fibonacci Number - Leetcode 509.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ class Solution {
88

99
// Time: O(2^n)
1010
// Space: O(n)
11+
// Naive Recursive Solution
1112
};
1213

1314

@@ -28,6 +29,7 @@ class Solution {
2829

2930
// Time: O(n)
3031
// Space: O(n)
32+
// Top Down DP With Memoization
3133
};
3234

3335

@@ -52,6 +54,7 @@ class Solution {
5254

5355
// Time: O(n)
5456
// Space: O(n)
57+
// Bottom Up DP With Tabulation
5558
};
5659

5760

@@ -76,6 +79,7 @@ class Solution {
7679

7780
// Time: O(n)
7881
// Space: O(1)
82+
// Bottom Up DP With Constant Space
7983
};
8084

8185

0 commit comments

Comments
 (0)