Daily bit(e) of C++ | std::all_of, std::any_of, std::none_of
Daily bit(e) of C++ ♻️45, The trio of boolean reduction algorithms: std::all_of, std::any_of and std::none_of.
The trio of boolean algorithms, std::all_of, std::any_of, and std::none_of, provide the corresponding boolean reductions on top of a unary predicate.
While the std::all_of and std::none_of return true for empty ranges, std::any_of requires a positive presence and will return false for an empty range.
The algorithms have both the C++17 parallel and C++20 range versions.