input: def factorial(num: int) -> int:
      """ Calculate the factorial of a given number.
      >>> factorial(7)
      5040
      >>> factorial(0)
      1
      """
  
  n = int(input("Enter a number: "))  
  print("Factorial of", n, "is", factorial(n))
output:     if num == 0:
          return 1
      else:
          return num * factorial(num - 1)