Struggling to understand how to loop this properly. How do I set up the initial arrays with "minimum length 1" and then loop through it?
Given an array of ints, minimum length 1, figure out which is larger between the first and last elements in the array, and set all the other elements to be that value. Return the changed array.
public int[] maxEnd(int[] a) {
}