Horje
calculefactorail en bash Code Example
calculefactorail en bash
factorial () { 
    if (($1 == 1))
    then
        echo 1
        return
    else
        echo $(( $( factorial $(($1 - 1)) ) * $1 ))
    fi
}
Source: askcodez.com
calculefactorail en bash
function factorial {
  typeset n=$1
  (( n < 2 )) && echo 1 && return
  echo $(( n * $(factorial $((n-1))) ))
}
Source: askcodez.com




Shell

Related
How to solve the time stamp is in the future error when you unpack a tar file on a system where the clock is behind the system clock on which you created the tar archive Code Example How to solve the time stamp is in the future error when you unpack a tar file on a system where the clock is behind the system clock on which you created the tar archive Code Example
how to install openjdk-8-jdk in kali Code Example how to install openjdk-8-jdk in kali Code Example
compiling c Code Example compiling c Code Example
Fixing Flutter ios build errors Code Example Fixing Flutter ios build errors Code Example
batch script directory Code Example batch script directory Code Example

Type:
Code Example
Category:
Coding
Sub Category:
Code Example
Uploaded by:
Admin
Views:
12