The type of recursion implemented in the following code is a tail recursion (True or False) ? Please explain/ justify your answer.
public class ClassTest {
public int test(int val) {
if (val <=>=>
return val +1;
}
else return test(val-1) - test(val-2);
public static void main(String[] args) {
ClassTest obj = new ClassTest();
int result = obj.test(4);
System.out.println("Output is: " + result);
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here