Nerdulator> put something in

Recognised as Base-16 literal

0x42

  • Base 16
  • 7 bits
  • = 66

0x42 is a hexadecimal literal equal to 66 in decimal. It needs 7 bits (1 bytes) of storage, and is 0x42 in hexadecimal and 1000010 in binary.

In every base

Decimal66
Binary1000010
Octal102
Hexadecimal42
Base 3222
Base 361U
Prefixed literals0x42 · 0o102 · 0b1000010

Bit width & storage

Significant bits7
Bytes needed1
Fits in 8 bitsYes
Fits in 16 bitsYes
Fits in 32 bitsYes
Fits in 64 bitsYes
Padded to 8 bits01000010
Padded to 32 bits00000000000000000000000001000010

Read another way

As an IPv4 address0.0.0.66
As a 24-bit colour#000042
As a Unicode code pointU+0042, "B"
As a byte count66 B
As a duration in seconds1 minute and 6 seconds

Bitwise operations

NOT (32-bit)4,294,967,229
Shift left by 1132
Shift right by 133
Population count2the number of set bits
Lowest set bit2

Keep nerding

Every link below is a page Nerdulator can generate from what it already knows about this value.

Neighbouring values

Also reads as

U+0042 (unicode character)

  • U+0042
  • B
  • Uppercase letter

U+0042 is code point 66 (B), an uppercase letter in the Basic Latin (ASCII) block of the Basic Multilingual Plane. It takes 1 byte in UTF-8 and 1 unit in UTF-16.

Open this reading on its own page →

Identity

Code pointU+0042
Decimal66
CharacterB
General categoryUppercase letter
BlockBasic Latin (ASCII)
PlaneBasic Multilingual Planeplane 0
Official nameNot includedthe Unicode Character Database is not bundled; a stale copy would be worse than none

Encodings

UTF-8421 byte
UTF-160042a single unit
UTF-3200000042
Binary1000010
Bytes in UTF-8 vs UTF-161 vs 2UTF-16 is not always smaller, even for non-Latin text

Writing it in code

HTML numeric entityB
HTML hex entityB
CSS escape\0042
JavaScript\u0042
Python\u0042
Percent-encoded (URL)%42

Things that catch people out

JavaScript string length1
Needs a surrogate pairNo
Safe in a URL unescapedYes

Keep nerding

Every link below is a page Nerdulator can generate from what it already knows about this value.

Nearby code points

Nerdulate something else

Nothing in mind? Surprise me · today’s page

Every value on this page was computed from “0x42” by Nerdulator’s computing engine. Nothing here was retrieved from a database of answers or written by a model.