Answer the question
In order to leave comments, you need to log in
Is it correct to make loops recursive?
JS example:
function test(){
rnd = Math.floor(Math.random() * 10);
//console.log(rnd);
if (rnd==6)
return rnd;
else
return test();
}
console.log(test());
Answer the question
In order to leave comments, you need to log in
an example of heresy.
because all this is replaced by
function test(){
return 6;
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question