changed tsp comparator