comefrom: <doocs>0238.Product of Array Except Self_1.py
code: def productExceptSelf( nums: List[int]) -> List[int]:
      n = len(nums)
      ans = [1] * n
      left = right = 1
      for i in range(n):
          ans[i] = left
          left *= nums[i]
      for i in range(n - 1, -1, -1):
          ans[i] *= right
          right *= nums[i]
      return ans
masked: def sample_funcname ( var_0 : List [ int ] ) -> List [ int ] :
      var_1 = len ( var_0 )
      var_2 = [ 1 ] * var_1
      var_4 = var_3 = 1
      for var_5 in range ( var_1 ) :
          var_2 [ var_5 ] = var_4
          var_4 *= var_0 [ var_5 ]
      for var_5 in range ( var_1 - 1 , - 1 , - 1 ) :
          var_2 [ var_5 ] *= var_3
          var_3 *= var_0 [ var_5 ]
      return var_2
  