It's trivial to write a function to determine the min/max value in an array, such as: ... Using Commons Lang (to convert) + Collections (to min/max) import java.util.
stackoverflow.com