Challenge for Basic Recursion
Challenge
decrease(7)
calls the method below. What will it print?
public void decrease(int n){
if(n==0){
//do nothing
}
else{
System.out.print(n+" ");
decrease(n-1);
}
}
Please sign in or sign up to submit answers.
Alternatively, you can try out Learneroo before signing up.