code: private static int argmax(final double[] values) {
          double max = -Double.MAX_VALUE;
          int max_index = -1;
          for (int i = 0; i < values.length; i++) {
              if (values[i] > max) {
                  max = values[i];
                  max_index = i;
              }
          }
  
          return max_index;
      }
docs: Return the index of the highest value in the array.
  @param values