#include #include #include int main() { const std::bitset<8> b8 { 0b110111 }; size_t index { 0 }; assert(index < b8.size()); std::cout << b8[index] << std::endl; index = 6; assert(index < b8.size()); std::cout << b8[index] << std::endl; }