added number field and declared implementation of the comparator interface