[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[ic] recursive perl subroutine
Hello group,
Someone in this thread asked if Interchange prevents
recursion in some way. I tested this with the following
code:
[perl]
sub factorial
{
my ($item1)=@_;
if ($item <= 1)
{
# jump out of recursion
return 1;
}
return $item1*factorial ($item1-1);
}
return factorial(6);
[/perl]
Worked like a charm, so IC does not prevent recursion. Did you
check error.log and your recursion terminate condition?
Regards,
Marc Brevoort