Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ std::string reverse_string(std::string_view original)
std::string result;

// pass it to the recursive helper function
helper(original, result);
recursive_helper(original, result);

// result now contains a reversed version of the string
return result;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ void recursive_helper(std::string_view input, std::string& output)
std::string reverse_string(std::string_view original)
{
std::string result;
helper(original, result);
recursive_helper(original, result);
return result;
}

Expand Down
Loading