From d3ab4a8303d9f67c7df28dc4d4ee48597e0eb215 Mon Sep 17 00:00:00 2001 From: Jainav Date: Tue, 12 May 2026 01:46:43 +0530 Subject: [PATCH] Update product_sum.py --- data_structures/arrays/product_sum.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data_structures/arrays/product_sum.py b/data_structures/arrays/product_sum.py index 4fb906f369ab..cb334b00ddd4 100644 --- a/data_structures/arrays/product_sum.py +++ b/data_structures/arrays/product_sum.py @@ -25,7 +25,7 @@ def product_sum(arr: list[int | list], depth: int) -> int: Recursively calculates the product sum of an array. The product sum of an array is defined as the sum of its elements multiplied by - their respective depths. If an element is a list, its product sum is calculated + their respective depths. If an element is a list, its product sum is calculated recursively by multiplying the sum of its elements with its depth plus one. Args: