In shell scripting how to find factorial of a number?
You have to use loop, see this link: http://ubuntuforums.org/showthread.php?t=1349272