input: Write a function named unique_factorial to calculate the cumulative factorial of a given integer. The cumulative factorial is defined as: unique_factorial(n) = n! * (n-1)! * (n-2)! * ... * 1! where n > 0. The function should take an integer as input and output the cumulative factorial for that number.
  assert unique_factorial(4) == 288
  assert unique_factorial(5) == 34560
  assert unique_factorial(7) == 125411328000
  assert unique_factorial(1) == 1
output: def unique_factorial(n):
      def factorial(x):
          result = 1
          for i in range(2, x + 1):
              result *= i
          return result
  
      cumulative_product = 1
      for i in range(1, n + 1):
          cumulative_product *= factorial(i)
      return cumulative_product