Finding minimum index with maximum value in Array