Traverse all even length subarrays
for i in range ( len ( a ) ) : NEW_LINE INDENT left = i NEW_LINE right = i + 1 NEW_LINE total1 = total NEW_LINE while ( left >= 0 and right < len ( a ) ) : NEW_LINE DEDENT