Change code for compareTo