#include <functional> bool Or(bool a, bool b){ return std::logical_or<>()(a, b); } bool Xor(bool a, bool b){ return std::not_equal_to<>()(a, b); } bool And(bool a, bool b){ return std::logical_and<>()(a, b); }
- #include <functional>
- bool Or(bool a, bool b){
if(!a){if(!b){return false;}}return true;- return std::logical_or<>()(a, b);
- }
- bool Xor(bool a, bool b){
return a != b;- return std::not_equal_to<>()(a, b);
- }
- bool And(bool a, bool b){
if(a){if(b){return true;}}return false;- return std::logical_and<>()(a, b);
- }