Operators

Bitwise and (&)

Try the free JavaScript compiler

Keeps set bits shared by both operands. Number operands become signed 32-bit integers; BigInt operands use their signed binary representation without that truncation.

Formal Syntax & Structure

javascript syntaxjavascript
left & right

Parameters & Attributes

NameTypeDescription
leftexpressionLeft operand.
rightexpressionRight operand; short-circuiting may skip evaluation where applicable.

Return Value

Number or BigInt

Result of the operation.

Working Example

Example Snippetjavascript
console.log(7 & 3);
JavaScript Reference