Concept Flow - Bit Manipulation Basics AND OR XOR NOT Left Right Shift
Start with two numbers
Apply AND (&)
→Result: bits set where both bits are 1
Apply OR (|)
→Result: bits set where at least one bit is 1
Apply XOR (^)
→Result: bits set where bits differ
Apply NOT (~)
→Result: bits flipped
Apply Left Shift (<<)
→Result: bits shifted left, zeros fill right
Apply Right Shift (>>)
→Result: bits shifted right, sign bit or zero fill
End
Start with two numbers, then apply bitwise AND, OR, XOR, NOT, left shift, and right shift operations step-by-step to see how bits change.