Skip to content

Instantly share code, notes, and snippets.

@HennIdan
Created February 26, 2017 09:34
Show Gist options
  • Save HennIdan/55127c124b9d571f92cc7d84cbee8cb6 to your computer and use it in GitHub Desktop.
Save HennIdan/55127c124b9d571f92cc7d84cbee8cb6 to your computer and use it in GitHub Desktop.
public int forEachLoopMaxInteger() {
int max = Integer.MIN_VALUE;
for (Integer n: integers) {
max = Integer.max(max, n);
}
return max;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment