Implemented MyComparator and tested