Question
Java long division recursion Hello I have a question about making a recursive method in java to do long division to print out the nth
Java long division recursion
Hello I have a question about making a recursive method in java to do long division to print out the nth digit after the decimal place:
Inputs will be taken in through scanner as follows:
A numerator
A divisor
A number n that prints out the nth digit after the decimal place.
For example:
1000/13 = 76.9230769231 so using the below input data should return the 2nd number after the decimal place which is 2
Input data:
1000
13
2
Example 2 :
1000/13 = 76.9230769231 so using the below input data should return the first number after the decimal place which is 9
Input data:
1000
13
1
Example 3:
1000/17 = 58.8235294118 so using the below input data should return the 4th number after the decimal place which is 5
Input data:
1000
17
4
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started