diff --git a/03_recursion/c++11/02_greet.cpp b/03_recursion/c++11/02_greet.cpp index c743a89..9af462f 100644 --- a/03_recursion/c++11/02_greet.cpp +++ b/03_recursion/c++11/02_greet.cpp @@ -17,6 +17,7 @@ void greet(std::string name) { cout << "Hello, " + name + "!" << endl; greet2(name); cout << "Getting ready to say bye..." << endl; + bye(); } diff --git a/04_quicksort/c++11/02_recursive_sum.cpp b/04_quicksort/c++11/02_recursive_sum.cpp index b75a820..652fe0c 100644 --- a/04_quicksort/c++11/02_recursive_sum.cpp +++ b/04_quicksort/c++11/02_recursive_sum.cpp @@ -10,7 +10,7 @@ T sum(std::vector arr) { T last_num = arr.back(); // save last number value arr.pop_back(); // and remove it from array for next recursive call - return first_num + sum(arr); + return last_num + sum(arr); } int main() {