JavaScript tutorial:
/= Operator

 

The (/=) operator is use to divide a variable by an expression.

Syntax

result /= expression

The /= operator syntax has these parts:

Part

Description

result

Any numeric variable.

expression

Any numeric expression.

Example

Using the /= operator is exactly the same as specifying:

result = result / expression

For information on when a run-time error is generated by the /= operator, see the Operator Behavior table.

See also: / Operator, Operator Behavior, Operator Precedence, Operator Summary