int peakIndexInMountainArray(int* arr, int arrSize){ int i=0; for (i=1; arr[i] > arr[i-1]; i++); return i-1; }