It is probably necessary to *REMOVE* the static keyword for most
of the variables.
If you use static, you get *one* copy of the variable for all of the
calls *combined*. This is not what you want for a recursive program,
although static read-only variables are not a problem.
That may or may not be what you want. It depends on what you're
doing.
If you want a single copy of a variable for all invocations of a
function, use "static". If you want a separately allocated copy for
each invocation, don't use "static". Recursion has very little to do
with the choice.
If you find yourself using "static" a lot, re-think what you're doing;
the vast majority of variables declared within functions should *not*
need to be static.
Note: Gordon deliberately and rudely deleted the attribution line for
"pereges", as he always does. I've re-inserted it. I do not grant
permission to quote this or any other article I post to Usenet without
attribution.