package Lesson4;

public class ArrayMinMaxValue {
    public static void main(String[] args) {
        System.out.println("max value: " + min + " and " "min value: " + max +);
    }
    public static int min(int[] arrayMin) {
        int minValue = Integer.MAX_VALUE;
        if (arrayMin.length != 0) {
            for (int i = 0; i < arrayMin.length; i++) {
                if (arrayMin[i] < minValue) {
                    minValue = arrayMin[i];
                }
            }
            return minValue;
        } else {
            System.out.println("  ");
            return 0;
        }
    }
    public static int max(int[] arrayMax) {
        int maxValue = Integer.MAX_VALUE;
        for (int i=0; i<arrayMax.length; i++) {
            if (maxValue < arrayMax[i]) {
                maxValue = arrayMax[i];
            }
        }
        return maxValue;
    }
}

@@ -11,16 +11,48 @@
 sson4;%0A%0A
+/**%0A *           %0A *      %0A */%0A%0A
 public c
@@ -120,32 +120,34 @@
 args) %7B%0A        
+//
 System.out.print
@@ -205,24 +205,25 @@
 x +);%0A    %7D%0A
+%0A
     public s
@@ -628,24 +628,25 @@
     %7D%0A    %7D%0A
+%0A
     public s
@@ -705,34 +705,34 @@
  = Integer.M
-AX
+IN
 _VALUE;%0A
         for 
@@ -711,32 +711,72 @@
 eger.MIN_VALUE;%0A
+        if (arrayMax.length != 0) %7B%0A    
         for (int
@@ -781,14 +781,18 @@
 nt i
-=
+ = 
 0; i
-%3C
+ %3C 
 arra
@@ -827,38 +827,46 @@
     
-if (maxValue %3C arrayMax%5Bi%5D) %7B%0A
+    if (arrayMax%5Bi%5D %3E maxValue) %7B%0A    
     
@@ -913,26 +913,32 @@
         
-%7D%0A
+    %7D%0A  
         
 %7D%0A      
@@ -929,26 +929,31 @@
         
-%7D%0A
+  %7D%0A   
         
 return m
@@ -936,32 +936,33 @@
    %7D%0A           
+ 
 return maxValue;
@@ -958,20 +958,107 @@
 n maxValue;%0A
+        %7D else %7B%0A            System.out.println(%22  %22);%0A            return 0;%0A        %7D%0A
     %7D%0A%7D%0A

add task