Factorial of a number n can be defined as product of all positive numbers less than or equal to n. For example, the factorial of 6 is 1 × 2 × 3 × 4 × 5 × 6 = 720

The following table provides few examples of factorial of a number.

Number | Factorial | Result |
---|---|---|

1! | 1 | 1 |

2! | 1 × 2 | 2 |

3! | 1 × 2 × 3 | 6 |

4! | 1 × 2 × 3 × 4 | 24 |

**Note**: In Mathematics, factorial of a number is represented by exclamation mark.

The following calculator will help you to find the factorial of any given number.

Number | Factorial | Result |
---|---|---|

4! | 1 × 2 × 3 × 4 | 24 |

3! | 1 × 2 × 3 | 6 |

2! | 1 × 2 | 2 |

1! | 1 | 1 |

Number | Calculation | Result |
---|---|---|

4! | 5! / 5 | 24 |

3! | 4! / 4 | 6 |

2! | 3! / 3 | 2 |

1! | 2! / 2 | 1 |

0! | 1! / 1 | 1 |

In this way a reasonable value for 0! can be found.

C Program to find Factorial of a Number
C++ Program to find Factorial of a Number
C# Program to find Factorial of a Number
Java Program to find Factorial of a Number
PHP Program to find Factorial of a Number
Python Program to find Factorial of a Number