Return the value of the maximum element in a non-empty array.