Factorial of n is the product of all positive descending integers. Factorial of n is denoted by n!

For example, n! = n * (n-1) * (n -2) * …….* 1

#### Factorial in Python :

```
number = int(input("Please enter any Number to find factorial : "))
fact = 1
for i in range(1, number + 1):
fact = fact * i
print("The factorial of %d is = %d" %(number, fact))
```

Output :

```
number = int(input("Please enter any Number to find factorial : "))
fact = 1
for i in range(1, number + 1):
fact = fact * i
print("The factorial of %d is = %d" %(number, fact))
```

## 0 comments:

## Post a Comment

Share your post related problems with us.