Skip to content

bigIntBitLength

bigIntBitLength(value): number

Defined in: packages/core/src/big-int/bit-length.ts:9

Number of bits in |value|, which is ⌊log₂|value|⌋ + 1. Zero for 0n.

Computed from the hexadecimal string rather than by shifting, so the cost is linear in the width rather than quadratic.

bigint

number