<qiyuangong>238_Product_of_Array_Except_Self_1.py
def productExceptSelf( nums):
    ans = [1] * len(nums)
    for i in range(1, len(nums)):
        ans[i] = ans[i - 1] * nums[i - 1]
    right = 1
    for i in range(len(nums) - 1, -1, -1):
        ans[i] *= right
        right *= nums[i]
    return ans
def sample_funcname ( var_0 ) :
    var_3 = [ 1 ] * len ( var_0 )
    for var_5 in range ( 1 , len ( var_0 ) ) :
        var_3 [ var_5 ] = var_3 [ var_5 - 1 ] * var_0 [ var_5 - 1 ]
    var_6 = 1
    for var_5 in range ( len ( var_0 ) - 1 , - 1 , - 1 ) :
        var_3 [ var_5 ] *= var_6
        var_6 *= var_0 [ var_5 ]
    return var_3
