This PR adds a new operation to the calculator program for computing the exponent of two numbers. The new operation allows the user to calculate A^B, where A is the base and B is the exponent.
Summary of Changes
Added a new function named 'exponent' to calculate the exponent of two numbers.
Integrated the new operation into the existing calculator function.
Added a new option in the operation selection menu for the exponent operation.
Handled the exponent operation in the main loop of the calculator function.
Updated the condition to quit the calculator to check if 'choice' is '6' instead of '5'.
Fixes #1.
To checkout this PR branch, run the following command in your terminal:
git checkout sweep/add-exponent-function_1
To get Sweep to edit this pull request, leave a comment below or in the code. Leaving a comment in the code will only modify the file but commenting below can change the entire PR.
Description
This PR adds a new operation to the calculator program for computing the exponent of two numbers. The new operation allows the user to calculate A^B, where A is the base and B is the exponent.
Summary of Changes
Fixes #1.
To checkout this PR branch, run the following command in your terminal:
To get Sweep to edit this pull request, leave a comment below or in the code. Leaving a comment in the code will only modify the file but commenting below can change the entire PR.