Howdy Ya'll!!
I have an assignment listed below with my code. It is fairly short . If you all could review that would be awesome ! Thanks in advance .
***** Assignment *****'
Purpose: To write an application that uses recursion to solve a problem.
Details: Create a class called Power that computes the value of base exponent.
The class should have one recursive method:
public static int power(int base, int exponent) – Which computes the value of base exponent using recursion, returning the result. The recursion step should use the following relationship
base exponent = base x base exponent - 1
and the termination condition should occur when exponent is equal to 1, because
base 1 = base
NOTE: For the power method, assume the exponent parameter value is always greater than 0.
Create a second class called PowerTest that contains the main method, and tests the Power.power method. The
test class does not need to ask for input from the user of the class, nor does it need to do any additional error checking.
Ensure that your program is properly formatted and it follows all
Java naming conventions.
*****Code ******
****Test***