return reduce(operator.add, xs)
addAll = foldl (+) 0
Doing foldl (+) 0 in C++ is done traditionally with something like (OK, still not that nice)
std::accumulate(v.begin(), v.end(), std::plus<int>(), 0)
It could be useful if you are building a general framework (like a calculator, or a game AI decision engine) for user-defined functions.