You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Content-->Convert the function to a non-recursive function using the simulating recursion method using stack.
int F(int n)
{
if(n<=1) return 1;
int a=n+F(n-1);
int b=n*F(n/2);
int c=n-2-(a+b)%2;
int d=F(c);
return a+b+d;
}