public static < T > T max ( T [ ] array ) { if ( array . length > 1 ) { Sorting . sortDesc ( array ) ; return array [ 0 ] ; } else { return null ; } }
Gets the max item from the array . Sorts the list descending first .