+ 1
There is not a sum function in the std library but you have std::accumulate located in algorithm.h. You could also do your own sum function or variable, which doesnt need to be int. A variable named sum stores the type you want it to store, same with functions and function return types.
4th Jul 2016, 6:15 PM
Garme Kain
Garme Kain - avatar