main.java
//Function to return min value of integer array
Function to return min value of integer array
Function to return min value of integer array
public static int MIN(int[] array){
        int min= Integer.MAX_VALUE;
        for (int x=0; x<array.length;x++){
            if(array[x]<min){
                min=array[x];
            }
        }
        return min;
    }
public static int MIN ( int [ ] array ) { int min = Integer . MAX_VALUE ; for ( int x = 0 ; x < array . length ; x ++ ) { if ( array [ x ] < min ) { min = array [ x ] ; } } return min ; }
Function to return min value of integer array
Function to return min value of integer array
//Set min to maximum possible value //loop for all array values //if value is less then min set min to value //return min