Returns the greatest value present in array, treating values as unsigned. @param array a nonempty array of unsigned int values @return the value present in array that is greater than or equal to every other value in the array according to #compare @throws
(int... array)
| 113 | |
| 114 | |
| 115 | public static int max(int... array) { |
| 116 | checkArgument(array.length > 0); |
| 117 | int max = flip(array[0]); |
| 118 | for (int i = 1; i < array.length; i++) { |
| 119 | int next = flip(array[i]); |
| 120 | if (next > max) { |
| 121 | max = next; |
| 122 | } |
| 123 | } |
| 124 | return flip(max); |
| 125 | } |
| 126 | |
| 127 | /** |
| 128 | * Returns a string containing the supplied unsigned {@code int} values separated by |
nothing calls this directly
no test coverage detected