Skip to content

Commit c0c2715

Browse files
authored
fix: self-test example not working
1 parent 4ca4333 commit c0c2715

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

CONTRIBUTING.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -81,8 +81,9 @@ assert(backtracking::subset_sum::number_of_subsets(0, array1) ==
8181
3. Small C++ program that showcases and explains the use of tests.
8282

8383
```cpp
84-
#include <vector> /// for std::vector
85-
#include <cassert> /// for assert
84+
#include <iostream> /// for IO operations
85+
#include <vector> /// for std::vector
86+
#include <cassert> /// for assert
8687

8788
/**
8889
* @brief Verifies if the given array
@@ -100,7 +101,7 @@ bool is_number_on_array(const std::vector<T> &arr, const int &number) {
100101
return true;
101102
}
102103
else {
103-
return false;
104+
// Number not in the current index, keep searching.
104105
}
105106
}
106107

0 commit comments

Comments
 (0)