Problem 2166 · Medium

Design Bitset

Maintain a bitset that supports setting, clearing, flipping every bit and counting ones. The visual shows the bit row, with a flip flag that reinterprets all bits at once.

Open the interactive visualisation