Closed Leo-MathGuy closed 1 year ago
boolean (true or false, 1 byte)
A boolean stores one bit not one byte
Technically a boolean could be represented by one bit. However, in Java and most languages the smallest assignable chunk of memory is one byte, so the size of a boolean in Java is indeed one byte.
k
boolean (true or false, 1 byte)
A boolean stores one bit not one byte