Given an array of integers, determine if it is a valid mountain array. A mountain array must have at least three elements, and there must exist an index where elements strictly increase up to that index and then strictly decrease thereafter.
Click Run to execute sample tests.