What condition does a recursive function have to fulfill to be well defined?

211 Views Asked by At

What condition does a recursive function have to fulfill to be well defined? Provide a well-defined recursive definition of the factorial of a number. Modify the definition so that is no longer well-defined

This is past year paper question for discrete maths course that I fail to understand what is it asking.

My understanding is that by default a recursive function is by default is well-defined, so there's no way to make it not well-defined.

As for factorial, my definition is like this:

$f(1) = 1$

$f(n) = f(n - 1) * n$

Now if I change this definition in a way to make it ambiguous, I wouldn't be able to get a factorial from it. I appreciate it if you could provide the answer to this question and clear my doubts.