// // none_of.h // stream // // Created by Sam Jaffe on 4/2/23. // #pragma once #include #include #include namespace stream::ranges { template bool none_of(It it, S end, Pred pred, Proj proj = {}) { for (; it != end; ++it) { if (detail::invoke(pred, *it, proj)) { return false; } } return true; } template bool none_of(Stream const & stream, Pred pred, Proj proj = {}) { return none_of(stream.begin(), stream.end(), std::ref(pred), std::ref(proj)); } }