Factorial script