My book has this as an example but I am lost as to what it does and it doesnt say what it does or break it down. I am trying desperately to learn recursive functionsCode:
int Count(float A[], int Size, float X)
{
if (Size <= 0)
{
return 0;
}
else
return (A[0] == X) + count(A + 1, Size - 1, X);
}
does it set each element in A to X
or does it return the number of elements in A