ups. modified how to compare integers because old method doesn't exist at java 5