diff --git a/Source/Problem13.cpp b/Source/Problem13.cpp index 27f3508..04c4570 100644 --- a/Source/Problem13.cpp +++ b/Source/Problem13.cpp @@ -253,6 +253,7 @@ void Problem13::reserveVectors(){ //Constructor Problem13::Problem13() : Problem("Work out the first ten digits of the sum of the one-hundred 50-digit numbers"), sum(0){ reserveVectors(); + setNums(); sum = 0; } @@ -266,9 +267,6 @@ void Problem13::solve(){ //Start the timer timer.start(); - //Setup the array - setNums(); - //Get the sum of all the numbers sum = mee::getSum(nums);