Skip to content

Glossary: Algorithms Beyond the Basics in JavaScript

Power of two

Also written: powers of two

A number such as 1, 2, 4, 8 that has exactly one 1 bit in binary. Giving each option a power of two keeps flags from sharing a bit.

Where the book teaches it

Related terms

BitmaskFlagBinary