Here you can find the source of minIndex(int[] array)
public static int minIndex(int[] array)
//package com.java2s; //License from project: Apache License public class Main { /**// w w w .jav a2 s .c o m * @return the minimum index in this array, */ public static int minIndex(int[] array) { int minIndex = 0; for (int i = 0; i < array.length; i++) { if (array[minIndex] > array[i]) { minIndex = i; } } return minIndex; } /** * @return the minimum index in this array, */ public static int minIndex(long[] array) { int minIndex = 0; for (int i = 0; i < array.length; i++) { if (array[minIndex] > array[i]) { minIndex = i; } } return minIndex; } /** * @return the minimum index in this array, */ public static int minIndex(double[] array) { int minIndex = 0; for (int i = 0; i < array.length; i++) { if (array[minIndex] > array[i]) { minIndex = i; } } return minIndex; } }