Skip to content

Instantly share code, notes, and snippets.

@RomanVlasenko
Created May 22, 2013 06:34
Show Gist options
  • Save RomanVlasenko/5625655 to your computer and use it in GitHub Desktop.
Save RomanVlasenko/5625655 to your computer and use it in GitHub Desktop.
public class Main {
public static void main(String[] args) {
Set<Integer> set = new TreeSet<Integer>(new Comparator<Integer>() {
@Override
public int compare(final Integer o1, final Integer o2) {
return 0;
}
});
set.add(1); set.add(2); set.add(1);
for (Integer integer : set) {
System.out.println(integer);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment