Skip to content

Commit 939ca4a

Browse files
fix: init of transform_reduce in dynamic_programming
1 parent 2b40841 commit 939ca4a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dynamic_programming/catalan_numbers.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class catalan_numbers {
2424

2525
value_type compute_next() {
2626
return std::transform_reduce(known.begin(), known.end(), known.rbegin(),
27-
static_cast<value_type>(), std::plus<>(),
27+
static_cast<value_type>(0), std::plus<>(),
2828
std::multiplies<>());
2929
}
3030

0 commit comments

Comments
 (0)