Used to raise a number to the power of an exponent.
result = number ^ exponent
||Any numeric variable.
||Any numeric expression.
||Any numeric expression. An exponent value is required.
The caret (^) is used as the exponentiation operator.
The exponent operator should not be confused with the base-10 exponent symbol. An uppercase letter E, or lowercase letter e can be used as a base-10 exponent (scientific notation) symbol in a numeric literal. These letters cannot be used as operators.
argument can be negative only if exponent
is an integer value. When more than one exponentiation is performed in a single expression, the ^ operator is evaluated as it is encountered from left to right.
The following example shows valid uses of the exponent operator (^) and the base-10 exponent symbol (E). Note that the usage x E y
is not valid, because E is a numeric literal character, not an operator.
Println x ^ y ' Returns 81
Println 3E4 ' Returns 30000