Skip to content

Commit

Permalink
quick fix
Browse files Browse the repository at this point in the history
  • Loading branch information
camilo committed Feb 19, 2024
1 parent c6c1462 commit f1cd535
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/include/algorithm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ namespace qlibs {
const size_t first = 0U,
const size_t last = n - 1U ) noexcept
{
for ( size_t i = first ; i < last; ++i ) {
for ( size_t i = first ; i <= last; ++i ) {
array[ i ] = value;
}
}
Expand All @@ -223,7 +223,7 @@ namespace qlibs {
{
T* found = nullptr;

for ( size_t i = first; i < last; ++i ) {
for ( size_t i = first; i <= last; ++i ) {
if ( array[ i ] == key ) {
found = &array[ i ];
break;
Expand Down

0 comments on commit f1cd535

Please sign in to comment.