Company: Arcesium_18oct
Difficulty: medium
Positive Product Problem Description You are given a sequence of `n` integers and you have to find the maximum length of a segment which gives positive product. Complete the `maxLength` function in your editor. It has 1 parameter: An array, `arr`, containing `n` elements of the sequence. It must return an integer denoting the maximum length of a segment which gives positive product. Examples Example 1: Input: 4 1 -2 -3 4 Output: 4 Explanation: Here maximum product is 1 * -2 * -3 * 4 = 24. Example 2: Input: 2 -3 5 Output: 1 Explanation: Here if we multiply both the two numbers then our product will be -3 * 5 = -15. Whether if we take only 5 it will give us maximum product. Constraints `1 Absolute value of each number is greater than 0 and less than or equal to 1000 (i.e., `0 The locked stub code in your editor reads the following Input from stdin and passes it to your function: First line contains number of integers `n` in the sequence. Followed by `n` lines each contain an element. You