Now we know that a [ i . . j ] is an increasing subarray . Remove non - positive elements from the left side as much as possible .
while ( i < j and arr [ i ] <= 0 ) : NEW_LINE INDENT i += 1 NEW_LINE DEDENT