+ 1

Is it possible to get a part from bitset<8> and put it into bitset<6>

Like bitset <8> bit8 = 01101011 Get (011010)11 And bitset<6> bit6 = (011010)?

4th Jun 2018, 9:32 AM
Ixidot
Ixidot - avatar
1 Odpowiedź
+ 1
you could of course do it by hand. i don‘t know of any method that does this. you could convert to string, use substr and construct a bitset from it, since the bitset constructor accepts a string of ones and zeroes
4th Jun 2018, 9:44 AM
Max
Max - avatar