https://xyzcode.blogspot.com/2020/07/...
Longest Turbulent Subarray
A subarray of A is said to be turbulent if and only if the comparison sign flips between each adjacent pair of elements in the subarray.
Return the length of a maximum size turbulent subarray of A.