E
E
Espleth2014-10-12 14:09:38
C++ / C#
Espleth, 2014-10-12 14:09:38

Why bool weighs a whole byte?

Indeed, in theory, one bit is enough to store it, and it weighs as a byte data type, into which 255 different numbers can be stuffed.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
B
batchar, 2014-10-12
@Espleth

Because the architecture of the computing system is not capable of addressing a BIT of memory, the minimum unit is a byte.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question