text: function indexOfMax(arr) {
    if (arr.length === 0) return -1
  
    let max = arr[0]
    let maxIndex = 0
    for (var i = 1; i < arr.length; i++) {
      if (arr[i] > max) {
        maxIndex = i
        max = arr[i]
      }
    }
  
    return maxIndex
  }
  
  export default indexOfMax
  