AI worksheet builder and 715 free math exercise generators — no subscription or registration required. Optional tips help keep them free. Tip →

Article

Bitwise AND

Go to Math Operation

Bitwise AND: how to solve

  1. Write the numbers in binary if they are not already shown that way. Bitwise AND compares numbers bit by bit.
  2. Line up the bits from right to left. If one number has fewer bits, add leading zeros so both strings have the same length.
  3. Apply the AND rule to each pair of bits:
    • 1 AND 1 = 1
    • 1 AND 0 = 0
    • 0 AND 1 = 0
    • 0 AND 0 = 0

So the result has a 1 only where both numbers have a 1 in the same position.

Helpful strategy

  • Work from the least significant bit on the right.
  • If the exercise gives decimal numbers, convert them to binary first, then do the bitwise AND.
  • Keep the bits in the same positions; do not add or multiply the numbers.

Check your answer

  1. Re-read each column and verify that only matching 1 bits produced 1.
  2. If needed, convert the final binary answer back to decimal to see whether it matches the expected value.
  3. Make sure the answer is simplified to its final form, with no extra steps left unfinished.

© 2023-2026 AI MATH COACH