## Q&A: Why is 0! = 1?

David R. of Palo Alto writes:

Have you ever discussed factorials on your podcast? I don’t recall,
but a friend and I are puzzled and so of course we turn to you: Why
is “zero factorial” 1? Was it simply defined that way to frustrate
all of us nonmath folks, or is there a valid explanation?

Well, David, I think it’s fair to say it was made up, but for a very very good reason. Many formulas involving factorials are simply more uniform if 0! = 1.

Here’s one way to think of it. 4!/4 clearly gives 3!.
Similarly 3!/3 gives 2!
2!/2 gives 1!
So of course, 1!/1 should be 0!, and so it is!
(But then (-1)! is 0!/0, which doesn’t work well at all!)

Combinatorial questions give another way to think of it. The number of ways to order n objects in a line is n!. How many ways are there to order 0 things? It’s not impossible (which would be 0 ways)—there is 1 way to do it! — don’t do a thing!

Similarly, the number of ways to marking k objects in a pool of n objects, say with a red crayon, is n! / (k! (n-k)!) This is the same as not marking the other (n-k) objects red, but, say, blue instead. Clearly there is one way to mark all the objects blue (i.e. mark none of them red). The formula only works if 0! is defined to be 1.

Another answer, closely related, is that n!, as a function of n, can be smoothed out and made continuous, by something called the Gamma Function. Gamma(n+1) = n!, and as it happens, Gamma(1) = 1 so 0! should be 1. (I bet you would never have guessed that (1/2)! is sqrt(pi)/2; well it isn’t, really, but Gamma(3/2) = sqrt(pi)/2

But the bottom line is, it’s really a matter of making a wise definition.