cant goto or while replace recursions
Posted: Tue Apr 19, 2011 11:33 am
Gentlemen
the languages that do not support tail call and recursions might lead to stackoverflow
cant the while or goto within the function accomplish the same task. surely with goto
one can reset the variables with certain checks when function code is about to be re-executed
i do understand that the calling of function from within itself might come handy in certain cases.
but is there something specific about it that cant be done with goto/while.
i am currently trying to get elements in array through reflection but am unable to get the desired results yet.
in that recursion does come handy when a array has array`s within. so if array has that many arrays within itself
that function recursion might cause stackoverflow i used goto. now fear of stackoverflow is not there. but i was wondering
is there something specific to recursion.
ThankingYou
RIGHT_THEN
the languages that do not support tail call and recursions might lead to stackoverflow
cant the while or goto within the function accomplish the same task. surely with goto
one can reset the variables with certain checks when function code is about to be re-executed
i do understand that the calling of function from within itself might come handy in certain cases.
but is there something specific about it that cant be done with goto/while.
i am currently trying to get elements in array through reflection but am unable to get the desired results yet.
in that recursion does come handy when a array has array`s within. so if array has that many arrays within itself
that function recursion might cause stackoverflow i used goto. now fear of stackoverflow is not there. but i was wondering
is there something specific to recursion.
ThankingYou
RIGHT_THEN