print("Welcome to the Factorial Calculator! Enter a number and this calculator will calculate it.\n")
num = int(input("Enter your number here:"))
val = 1
amount = num
if num == 0:
print("\nThe factorial of 0 is 1")
elif num < 0:
print("\nPlease enter a positive number for negative numbers have infinite and undefined values when it comes to factorials.")
else:
for i in range(1,num+1):
val *= i
print(f"\n{amount} factorial is equal to {val}")
To embed this project on your website, copy the following code and paste it into your website's HTML: