You are viewing a single comment's thread. Return to all comments →
int min = scores.get(0); int max = scores.get(0); int minRecord = 0; int maxRecord = 0; for (int i = 1; i < scores.size(); i++) { if (scores.get(i) < min) { min = scores.get(i); minRecord++; } else if (scores.get(i) > max) { max = scores.get(i); maxRecord++; } } return Arrays.asList(maxRecord, minRecord);
Seems like cookies are disabled on this browser, please enable them to open this website
Breaking the Records
You are viewing a single comment's thread. Return to all comments →
Java