Exponents

The Exponents API calculates the result of a number raised to a power.

Parameters

  • base: The base number
  • power: The power to which the base is raised

Example Usage

exponents = Exponents()  
result = exponents.fn(2, 3)  
print(result)  # Output: 8