My my factorial functions return 1 for any negative value

When n is negative, the range is empty, and reduce(*,) starts with the multiplicative identity which is 1.

4 Likes