how to access the last number in an array list code example Example: java last element in array arrayName[arrayName.length() - 1];