Skip to content

Instantly share code, notes, and snippets.

@phl0w
Created July 12, 2012 21:36
Show Gist options
  • Select an option

  • Save phl0w/3101196 to your computer and use it in GitHub Desktop.

Select an option

Save phl0w/3101196 to your computer and use it in GitHub Desktop.
public class Challenge {
public static void main(String... args) {
System.out.println(function(8));
}
public static int function(int a) {
int temp = 0;
for (int i = 0; i <= a; i++) {
temp += i;
}
return temp;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment