Skip to content

Commit 63319b7

Browse files
Update dynamic_programming/factorial_top_down_dp.cpp
Co-authored-by: realstealthninja <[email protected]>
1 parent e3c39de commit 63319b7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dynamic_programming/factorial_top_down_dp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
#include <cassert> // For test cases
1616

1717
/// Array to store computed factorials for memoization
18-
long long memo[1000] = {0};
18+
std::array<uint64_t, 1000> memo{0};
1919

2020
/**
2121
* @brief Computes the factorial of a non-negative integer using recursion and memoization.

0 commit comments

Comments
 (0)