Created factorial function
Added the test
Merge pull request #3 from RoyalSpree/master

Factorial function