Formula for factorial? I need an equation that defines factorial without using factorial, that also works for $0$.
I have seen factorial defined like this:
$$n! = 1\cdot2\cdot3\cdot4\cdots n$$
But if we plug $0$ into that, we end up with $0$, which doesn't work.
So what would be the correct way to put it?
 A: In your definition, if we plug $0$ into that we don't get $0$. Because your definition starts with $1$, so the case for $n = 0$ simply isn't defined. Usually it is defined $0! = 1$.
You can therefore define factorial like this:
$$n! = \begin{cases}1 & n = 0\\
1\cdot2\cdots n & n > 0
\end{cases}$$
Alternatively, if you don't like the above definition, you could use the Gamma function definition:
$$\Gamma(t) = \int_0^\infty x^{t - 1}e^{-x}\,\mathrm dx$$
and the put
$$n! = \Gamma(n + 1).$$
Note that the Gamma function is defined for real values, whereas the factorial only for natural numbers.
A: *

*Let $A = \{a_1, \dots , a_n\}$ be a finite set of numbers. Then
$$\prod_{a\in A} a = a_1 a_2 \cdots a_n$$
and by convention $\Pi_{a\in \emptyset} = 1$, therefore you can define factorial as $$f(n) = \prod_{1 \leq k \leq n} k\text{.}$$
In this case, $f(0) = \prod_{k\in \emptyset}k = 1$.

*Also, you can define factorial in the terms of gamma function:
$$f(n) =\int_{0}^{\infty} t^{n}e^{-t}dt\text{.}$$

*The third option is a combinatorial definition. Define $n!$ as a number of bijections $$g:\{1, 2, \dots , n\}\to \{1, 2, \dots , n\}\text{.}$$
Again, $0!$ is somehow special, since you have to notice that there is exactly one empty function $g:\emptyset \to \emptyset$.

*The last one, I can come up with is
$$f(n) = \frac{1}{c_n}\text{,}$$
where $c_n$ are uniquely determined coeffients of the Taylor's series of the exponential function: $$e^x = \sum_{n = 0}^{\infty}c_n x^n\text{.}$$
A: When thinking about combinations, we can derive a 
formula for "the number of ways of choosing k things from a collection 
of n things." The formula to count out such problems is  $n!/k!(n-k)!$.
For example, the number of handshakes that occur when everybody in a group of $5$ people shakes hands can be computed using $n = 5$ (five people) and $k = 2$ ($2$ people per handshake) in this formula. (So the answer is $5!/(2! 3!) = 10$).
Now suppose that there are $2$ people and "everybody shakes hands with everybody else."  Obviously there is only one handshake. But what happens if we put $n = 2$ ($2$ people) and $k = 2$ ($2$ people per handshake) in the formula? We get $2!/(2!0!)$.  This is $2/(2x)$, where $x$ is the value of $0!$. The fraction reduces to $1/x$, which must equal $1$ since there is only $1$ handshake. The only value of $0!$ that makes sense here is $0! = 1$.  
And so we define $0! = 1$.
more here
A: If you just want it to work with 0, use
$$
0!=1\\
(n+1)!=(n+1)\cdot n!
$$
The other options have been covered in other answers.
