Operators
Exponentiation (**)
Raises the left numeric operand to the right power. It groups right-to-left. A directly preceding unary operator on the base requires parentheses; negative BigInt exponents are invalid.
Formal Syntax & Structure
javascript syntaxjavascript
left ** rightParameters & Attributes
| Name | Type | Description |
|---|---|---|
| left | expression | Left operand. |
| right | expression | Right operand; short-circuiting may skip evaluation where applicable. |
Return Value
Number or BigInt
Result of the operation.
Working Example
Example Snippetjavascript
console.log(2 ** 3 ** 2);