factorial has to begin from 1
three bugs deciding the range of each iteration
add test cases
replace factorial with built-in math function
add iterative implementation
add comments