Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
This comment is hidden because it contains spoiler information about the solution
I am a beginner and I am wondering if it is worth it to add a whole library to the project only to use the simple accumulate function which can be done with one line of ranged for loop.
Really nice answer, i tried using a ternery but couldnt quite do it successfully.
I do know regex :) What I didn't know was how to manage gsub with it and it is actually more difficult to read what is considered the top answer.
Experience not cheating.
My code can work for all collections, yours only for std::vector.
cheating...
I had this issue when I ended up not returning anything from a function that had a return value (non void function skipped its return statement).
Same answer here.... we really need to learn some Regex...
This comment is hidden because it contains spoiler information about the solution
Your current solution prints the number to the screen and returns void.
Instead, your function should return the rounded number.