see title; mostly: what does h/t mean? (Google is awful at finding text with slashes and recommended to replace it for "hot", and ignores the slash when explicitly told to search for h/t)
Note that sending the bitset variable to std::cout prints the value of all the bits in the bitset.
Remember that the initialization value for a bitset is treated as binary, whereas the bitset functions use bit positions!
std::bitset also supports the standard bit operators (operator|, operator&, and operator^), so you can still use those if you wish (they can be useful when setting or querying multiple bits at once).
We recommend using std::bitset instead of doing all the bit operations manually, as bitset is more convenient and less error prone.
(h/t to reader “Mr. D”)
(source Source: http://www.learncpp.com/cpp-tutorial/3-.8a-bit-flags-and-bit-masks/#crayon-58e164d3d9745720727985 — Bit flags and bit masks, just
Just below the linked code, just above "bit masks". useUse ctrl-f if you don't see it).