Home

0b00100101

0b00100101 is a binary literal used in programming languages that recognize the 0b prefix to denote binary numbers. The sequence comprises eight bits.

Value: As an unsigned binary number, 0b00100101 equals decimal 37 and hexadecimal 0x25. The ones occur at

Context and usage: Such a literal defines a specific bit pattern for initialization or for bitwise operations

See also

- Binary literal

- Bitmask

- Two's complement

- ASCII

bit
positions
0,
2,
and
5
(counting
from
the
least
significant
bit),
giving
a
bitmask
of
1
+
4
+
32
=
37.
(AND,
OR,
XOR,
NOT).
It
can
represent
a
set
of
flags
or
a
mask
in
low-level
programming
tasks.
In
ASCII,
the
byte
0x25
corresponds
to
the
character
'%'.
In
an
8-bit
byte
context,
the
most
significant
bit
is
0,
so
the
value
is
non-negative
in
two's
complement
representation.