Can you please tell me how does this java code work? :
public class Main {
public static void main (String[] args) {
Strangemethod(5);
}
public static void Strangemethod(int len) {
while(len > 1){
System.out.println(len-1);
Strangemethod(len - 1);
}
}
}
I tried to debug it and follow the code step by step but I didn't understand it.
update: sorry I didn't mention that I know the result of this code but just want to know the steps of the execution..