Maybe use `Integer.compare(int, int)`? http://docs.oracle.com/javase/7/docs/api/java/lang/Integer.html#compare(int, int)