LeetCode 238: Product of Array Except Self
Problem Restatement We are given an integer array nums . We need to return an array answer where: answer[i] = product of all nums[j] where j != i We must solve it: In O(n) time Without using division LeetCode gives this example: Input: nums = [1,2,3,4] Output: [24,12,8,6] The product of any prefix or suffix is guaranteed to fit in a 32-bit integer. Input and Output Item Meaning Input Integer...