This pull request adds a new function to the calculator program that allows users to calculate the exponent of a number. The new function, named 'exponent', takes two arguments, 'base' and 'exponent', and returns the result of 'base' raised to the power of 'exponent'.
Summary of Changes
Added a new function named 'exponent' in the 'calculator.py' file.
The 'exponent' function takes two arguments, 'base' and 'exponent', and returns the result of 'base' raised to the power of 'exponent'.
Integrated the 'Exponent' operation into the existing 'calculator' function.
Added a new print statement to display the 'Exponent' operation as an option to the user.
Added a new 'elif' statement to handle the 'Exponent' operation in the 'calculator' function.
The 'elif' statement calls the 'exponent' function with the user input values and prints the result in the same format as other operations.
Please review and merge this pull request to add the new functionality to the calculator program.
Fixes #1.
To checkout this PR branch, run the following command in your terminal:
git checkout sweep/add-exponent-function_1
🎉 Latest improvements to Sweep:
Use Sweep Map to break large issues into smaller sub-issues, perfect for large tasks like "Sweep (map): migrate from React class components to function components"
Getting Sweep to format before committing! Check out Sweep Sandbox Configs to set it up.
We released a demo of our chunker, where you can find the corresponding blog and code.
💡 To get Sweep to edit this pull request, you can:
Leave a comment below to get Sweep to edit the entire PR
Leave a comment in the code will only modify the file
Edit the original issue to get Sweep to recreate the PR from scratch
Description
This pull request adds a new function to the calculator program that allows users to calculate the exponent of a number. The new function, named 'exponent', takes two arguments, 'base' and 'exponent', and returns the result of 'base' raised to the power of 'exponent'.
Summary of Changes
Please review and merge this pull request to add the new functionality to the calculator program.
Fixes #1.
To checkout this PR branch, run the following command in your terminal:
🎉 Latest improvements to Sweep:
💡 To get Sweep to edit this pull request, you can: