public int CompareTo(TranslationCount other) { if (ReferenceEquals(this, other)) { return(0); } if (other is null) { return(1); } var linesComparison = Lines.CompareTo(other.Lines); return(linesComparison != 0 ? linesComparison : TranslatedLines.CompareTo(other.TranslatedLines)); }