Java Array Max Value max(int[] as)

Here you can find the source of max(int[] as)

Description

max

License

Open Source License

Declaration

public static int max(int[] as) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static int max(int[] as) {
        int result = -1;
        for (int a : as) {
            result = Math.max(result, a);
        }/*from w w w  . j a  va 2s.  c o m*/
        return result;
    }
}

Related

  1. max(int[] array)
  2. max(int[] array)
  3. max(int[] array)
  4. max(int[] array)
  5. max(int[] array)
  6. max(int[] data)
  7. max(int[] elements)
  8. max(int[] ids)
  9. max(int[] in, int x1, int x2)