The ^ operator is used to raise one number to the power of another.

Disco> 2 ^ 5
Disco> 2 ^ 0
Disco> 2 ^ (-5)
Disco> (-3) ^ (-5)

If the exponent is a natural number, the result will have the same type as the base. If the exponent is an integer, the result will be fractional or rational, depending on the type of the base.

Fractional exponents may not be used, as the result could be irrational, and Disco has no way to represent irrational numbers. For example, \(2^{1/2} = \sqrt{2}\).