Rosetta code factorial