this is a comparator for txt