Our papers are 100% unique and written following academic standards and provided requirements. Get perfect grades by consistently using our writing services. Place your order and get a quality paper today. Rely on us and be on schedule! With our help, you'll never have to worry about deadlines again. Take advantage of our current 20% discount by using the coupon code GET20
Order a Similar Paper Order a Different Paper
Determining the Square Root of a Number Via Recursion For this programming project you will develop an recursive function to find the square root of a number. The function should the number for which we are determining the square root and any other arguments you deem necessary. The recursion should terminate when the calculated square root produces a squared value within 0.001 of the value we are finding the square root of.
The following is required:
1. The user should be prompted to input a positive number.
2. The program should check to determine whether the user entered a valid number, i.e. -4.0 doesn’t work.
3. The program should call a function called: recursive sqrt(argument, argument, ….) .
4. The recursive square root function should continue to call itself until the value calculated for the square root when squared is within 0.001 of the value for which we are calculating the square root.
5. Your calculated value of the square root should be printed to the screen.