Added compareTo
Removed console logging