End of Year Sale: Use Coupon Code END2025 to Get Extra 25% Off.
calculateSubtreeSum that performs a post-order traversal and calculates the subtree sum for each node.null, return 0.calculateSubtreeSum for the left and right children of the current node.