[[
wikihub
]]
Search
⌘K
Explore
People
For Agents
Sign in
Explore
People
For Agents
Sign in
@jemoka / Jemoka Knowledge Base / raw/concept/kbhbitmask.md
Suggest edit
Cancel
Submit suggestion
Title
Name
Note
--- title: "bitmask" source: https://www.jemoka.com/posts/kbhbitmask/ --- bitmasking is a very helpful to create bit vectors. | with a 1-mask is useful to turning things on & with a 0-mask is useful to turning things off (bitvector & not(1-mask)) | is useful for set unions & is useful for intersections of bits ^ is useful for flipping isolated bits: 0 is bit preserving, 1 is bit negating ~ is useful for flipping all bits