The factorial function is defined to be n! = n*(n-1)*(n-2)*...*(2)*1, for integers n greater than or equal to 1. The recurrence relation corresponding to this is: (n+1)! = (n+1)*(n!), with initial condition 0! = 1.
Thus 0! = 1! = 1.
As to the original poster's question....
In general, [f(x) = f(y) implies that x = y] if and only if f is a one--to-one function. Here, the factorial function is not a one-to-one function, since 0! = 1! = 1.
"The factorial function is defined for integers n greater than or equal to 1". That is true. Hence, the factorial function n! is not defined for n=0. That is, 0! is not defined. Now you define 0!=1, a contradiction.
The problem relies behind 0!=1.
From where you brought this initial condition
"with initial condition 0! = 1" ???
How could you justify this initial condition?
The only way to define 0! is to set 0!=г(1)
and evaluate г(1) from the integral form of Gamma Function.