Operators

Division assignment (/=)

Try the free JavaScript compiler

Divides the current target by the right operand and writes the quotient. Number division by zero can yield infinity or NaN, whereas BigInt division by zero throws.

Formal Syntax & Structure

javascript syntaxjavascript
target /= value

Parameters & Attributes

NameTypeDescription
targetassignment targetWritable binding or property; evaluated once.
valueexpressionRight operand used by the underlying operation.

Return Value

operation result

The value written to the target.

Working Example

Example Snippetjavascript
let n = 12;console.log(n /= 3);
JavaScript Reference