# BITAND

Formulas / BITAND
The BITAND formula performs a bitwise AND operation on two integers, comparing each pair of corresponding bits and returning an integer result where each bit is the logical AND of the corresponding bits in the input integers.
`BITAND(number1, number2)`
• number1 - The first integer for the bitwise AND operation.
• number2 - The second integer for the bitwise AND operation.

## Examples

• `=BITAND(12, 7)`

This formula performs a bitwise AND operation on the integers 12 (binary 1100) and 7 (binary 0111), resulting in the integer 4 (binary 0100).

• `=BITAND(25, 15)`

This formula performs a bitwise AND operation on the integers 25 (binary 11001) and 15 (binary 01111), resulting in the integer 9 (binary 01001).

## Summary

The BITAND formula performs a bitwise AND operation on two integers and returns the result as an integer.

• The BITAND function is a mathematical function that performs a bitwise AND operation on two integers, comparing each pair of corresponding bits and returning an integer result.
• BITAND takes two arguments, "number1" and "number2," which represent the integers to be compared bit by bit in the bitwise AND operation.
• If the arguments provided to BITAND are not valid integers, the function returns a #NUM! error. Fractional numbers are truncated to integers before the operation.
• BITAND can handle negative integers, which are represented in two's complement form for the bitwise AND operation.

What does the BITAND function do?
The BITAND function performs a bitwise AND operation on two integers, comparing each pair of corresponding bits and returning an integer result where each bit is the logical AND of the corresponding bits in the input integers.
What are the arguments of the BITAND function?
The BITAND function has two arguments: "number1" and "number2." Both arguments represent the integers to be compared bit by bit in the bitwise AND operation.
What happens if the arguments provided to BITAND are not valid integers?
If the arguments provided to BITAND are not valid integers, the function returns a #NUM! error.
Can BITAND handle negative integers?
Yes, BITAND can handle negative integers. Negative integers are represented in two's complement form, and the bitwise AND operation is performed accordingly.
How does BITAND handle fractional numbers?
If fractional numbers are provided as arguments to BITAND, the function will truncate the numbers to integers before performing the bitwise AND operation. 