top of page
Click here to go to the home page of AskTheCode.

Python Program for factorial of a number

Asked: Anonymously |Category: Python

n=eval(input("Enter the number"))

temp=n

fac=1

while temp>0:

fac*=temp

temp-=1

print('factorial of',n,'is',fac)

Recent Posts

See All

Comentarios


bottom of page